Re: ALTER TABLE TableName DISABLE TRIGGER error
- From: "Uri Dimant" <urid@xxxxxxxxxxx>
- Date: Mon, 17 Mar 2008 16:05:42 +0200
See if this helps
ALTER TABLE MyTable DISABLE TRIGGER ALL
"Leonardo Arena" <LeonardoArena@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:CC845E13-A7EE-4BF9-A4A7-C46F40581FDF@xxxxxxxxxxxxxxxx
I connect to MSSQL 2000 SP4 server through an Application Role and execute
a
store procedure on DatabaseA
This first procedure calls another store procedure in a DatabaseB on the
same server.
All objects in the two databases have the same owner (dbo), and cross
database ownership chaining is enabled on both databases.
In the second procedure of DatabaseB, some insert, delete and update
statements are performed in a table MyTable residing on the same
DatabaseB.
Now the problem, in this store procedure, all insert, delete and update
statements work fine,
but when executing the command "ALTER TABLE MyTable DISABLE TRIGGER" an
error occurs: Error: 3704, Severity: 16, State: 1
We discovered that the ALTER TABLE command forces the audit of object
permission, and then the use of guest user instead of the application role
identity.
So if in the second database we authorize guest user as a db_owner or
db_ddladmin, the store procedure works, but this is really not an
advisable
option on real enviroment!
We checked and all Sql 'object permission' over the two databases are
correctly given. Could it be a problem of Sql 'statement permission' ?
Has anybody any suggestion on how to resolve this issue?
Thank you for help!
.
- Prev by Date: Re: i would like to see who executed a select statement on a specific table
- Next by Date: Re: Restricting Access priviledge on SQL2000
- Previous by thread: Re: Setting up a new database for application
- Next by thread: Re: ALTER TABLE TableName DISABLE TRIGGER error
- Index(es):