The information in this article applies to:
SYMPTOMS
Assume database1 and database2 both have SA as DBO, and both have
User1 as database users. In database2, the DBO creates a stored
procedure, SP1, which depends on a table, TABLE1, in database1 and
grants the execution permission of stored procedure SP1 to User1.
User1 can run the stored procedure SP1 until TABLE1 in database1
is dropped and recreated. After TABLE1 is dropped and recreated,
when executing SP1, User1 will receive the following error
message:
If the DBOs of the two databases are set to someone other than SA, User1 will be denied permission to access the underlying object the first time, or any time they try to run the stored procedure; which is exactly as documented. CAUSE
Page 130 of the "System Administrator's Guide" states: "If the
same user owns a stored procedure and all the views or tables it
references, and if the procedure and the objects it references are
all in the same database, SQL Server checks only the permissions
on the procedure."
WORKAROUNDRecreate the stored procedure SP1 and re-grant the permission to the user in database2 when the table in database1 is dropped and recreated. STATUSMicrosoft has confirmed this to be a problem in Microsoft SQL Server version 4.2 and SQL Server version 4.2a for OS/2. We are researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available. Additional query words: permission Windows NT
Keywords : kbother kbbug4.20 kbbug4.20a SSrvServer SSrvWinNT |
Last Reviewed: March 16, 1999 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |