FIX: "Generate SQL Script" in Enterprise Manager May Not Script Out the Correct Permissions

This article was previously published under Q280361
This article has been archived. It is offered "as is" and will no longer be updated.
BUG #:58293 (SQLBUG_70)
BUG #:57477 (SQLBUG_70)
Symptoms
The Generate SQL Script menu item in the SQL Server Enterprise Manager may not script out correct permissions if you do grant permissions in either of the following ways:

  • Use of the DENY UPDATE command on one table followed by the use of a GRANT UPDATE command on one or more columns of the same table.


    For example:
    deny update  on dbo.authors  to user1gogrant update on dbo.authors(address) to user1go						
    If you use the Generate SQL Script menu item in SQL Server Enterprise Manager, you get the following scripts:
    DENY  UPDATE  ON [dbo].[authors]  TO [user1] CASCADE GODENY  UPDATE  ON [dbo].[authors] (	[address], 	[address]	) TO [user1] CASCADE GO						
  • You grant table level permissions before you grant column level permissions in a single GRANT statement without using WITH GRANT OPTION.

    For example:
    grant insert, update on authors (au_lname) to user1go						
    If we use the Generate SQL Script menu item in the SQL Server Enterprise Manager, you get the following scripts:
     GRANT  INSERT  ON [dbo].[authors]  TO [user1]GO						
    You do not see the GRANT statement for the update permission.
The scripts output might be wrong in different ways according to the different GRANT statements.
Workaround
Manually change the permissions according to the business requirements.
Status
Microsoft has confirmed this to be a problem in SQL Server 7.0. This problem has been corrected in U.S. Service Pack 3 for Microsoft SQL Server 7.0. For more information, click the following article number to view the article in the Microsoft Knowledge Base:
274799 INF: How to Obtain Service Pack 3 for Microsoft SQL Server 7.0 and Microsoft Data Engine (MSDE) 1.0
For more information, contact your primary support provider.
sql70sp3fix
Properties

Article ID: 280361 - Last Review: 11/02/2013 01:15:00 - Revision: 3.0

  • Microsoft SQL Server 7.0 Standard Edition
  • kbnosurvey kbarchive kbbug kbfix KB280361
Feedback