Results 1 to 5 of 5
  1. #1
    Join Date
    Nov 2004
    Posts
    128

    Unanswered: What are "references" permissions?

    Whats the definitoin. I've been digging for a while, but cannot locate.

    TIA, cfr

  2. #2
    Join Date
    Dec 2002
    Posts
    1,245
    Quote Originally Posted by cfr
    Whats the definitoin. I've been digging for a while, but cannot locate.

    TIA, cfr
    Do you mean Declarative Referential Integrity (DRI)?

    Quote Originally Posted by SQL BOL
    The REFERENCES permission on a table is needed in order to create a FOREIGN KEY constraint that references that table.

    The REFERENCES permission is needed on an object in order to create a FUNCTION or VIEW with the WITH SCHEMABINDING clause that references that object.
    Regards,

    hmscott

    Edit to add: I found this entry buried in the text of topic GRANT (described) in SQL BOL for 2000 (updated)
    Have you hugged your backup today?

  3. #3
    Join Date
    Nov 2004
    Posts
    128
    My apologies as I should have been more specific. There is a permission in 2005 called References. I can find a couple of things that it's required for, but not exactly what it is.

  4. #4
    Join Date
    Dec 2002
    Posts
    1,245
    Quote Originally Posted by cfr
    My apologies as I should have been more specific. There is a permission in 2005 called References. I can find a couple of things that it's required for, but not exactly what it is.
    Ugh. It appears that REFERENCES is a valid permission at several layers in SQL 2005. There are REFERENCES permissions for several securable objects:

    table objects (same as SQL 2000, see above)

    scalar- and table-valued udfs and stored procs (same as SQL 2000)

    views (same as SQL 2000)

    contracts (dunno, new feature)

    database (seems to imply that if you grant a permission at this level, it will apply to all objects in a database)

    I'm going out on a limb here, I don't KNOW the answer, but here's a stab: since the REFERENCES permission on a table permits the user to constrain the object (by, for example, adding a foreign key to a table, would a REFERENCES permission on other objects allow a user to constrain the use of the object?

    Sorry, it's an interesting subject. I'm still reading up on SQL 2005 (in prep for our migration here). Would be interested in a more definitive answer.

    Regards,

    hmscott
    Have you hugged your backup today?

  5. #5
    Join Date
    Nov 2004
    Posts
    128
    Quote Originally Posted by hmscott
    Would be interested in a more definitive answer.
    As would I. I have some theories as well, but it's a bit frustrating that it's not spelled out in BOL the way other permissions are. I've also done some digging on the web and cant find anything. I'll keep everyone posted if anything turns up .

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •