BUG: BOL incorrectly states that a member of db_owner role can issue SETUSER command (231403)



The information in this article applies to:

  • Microsoft SQL Server 7.0
  • Microsoft SQL Server 2000 (all editions)

This article was previously published under Q231403
BUG #:55519 (SQLBUG_70), 56942 (SQLBUG_70), 216526 (SHILOH_BUGS)

SYMPTOMS

The following sections in SQL Server 7.0 and SQL Server 2000 Books Online incorrectly state that a member of the db_owner role can issue the SETUSER command:
  • SETUSER (TSQL)
    The first sentence in the Remarks section incorrectly references db_owner.

    Note This problem is resolved in the SQL Server Books Online January 2004 Update.
  • GRANT (TSQL)
    The second table incorrectly contains a row for SETUSER.

    Note This problem is resolved in the SQL Server Books Online January 2004 Update.
  • UserName Property (SQL-DMO)
    The Remarks section incorrectly references db_owner.
In addition, the Permissions paragraph in the SETUSER (TSQL) section of SQL Server 7.0 Books Online incorrectly references db_owner.

STATUS

Microsoft has confirmed this to be a problem in SQL Server 7.0.
Microsoft has confirmed this to be a problem in SQL Server 2000.

MORE INFORMATION

SETUSER permission is given only to members of the sysadmin role; this permission is not transferable.

When a member of the db_owner role executes the SETUSER command, the statement correctly fails with the following error message:
Server: Msg 262, Level 14, State 3, Line 1
SETUSER permission denied, database 'TestDB', owner 'dbo'.
IMPORTANT: SETUSER is included in SQL Server 7.0 and SQL Server 2000 for backward compatibility only; its usage is not recommended.

REFERENCES

To download the SQL Server Books Online January 2004 Update, visit the following Microsoft Web site:

To download the SQL Server 7.0 Books Online, visit the following Microsoft Web site:

Modification Type:MinorLast Reviewed:7/31/2006
Keywords:kbBug kbpending KB231403