Link to home
Start Free TrialLog in
Avatar of raGadiraju
raGadiraju

asked on

Permissions issue

Hi:

I am running the following sql query:

update dbo.tblClientid SET dbo.tblClientid.ISLOGICALLYDELETED = 1
FROM dbo.tblClientid
    INNER JOIN Auxiliary.di.TMP_CLIENTIDKEYS
    ON (Auxiliary.di.TMP_CLIENTIDKEYS.ClientIdKey = dbo.tblClientid.ClientIdKey);

I am getting the following error::
The UPDATE permission was denied on the column 'ClientIDKey' of the object 'tblClientId',
database 'ProdReporting',
schema 'dbo'


I have permissions to update the column ISLOGICALLYDELETED. I can't undersatnd why I am getting this error 'ClientIDKey'  when I am not updating the column.
Avatar of QPR
QPR
Flag of New Zealand image

any update triggers on the table you are trying to update?
Avatar of raGadiraju
raGadiraju

ASKER

NO. Its a plain update statement.
plain update statement?
Regardless of how plain or fancy an update statement is an update trigger on a table will still fire unless disabled.
Try scripting out the table structure and looking at it, any constraints, defaults, triggers?
Try removing the table reference from the column specification:
UPDATE dbo.tblClientid SET ISLOGICALLYDELETED = 1 ...
Guys I figured out what the issue was. This update was not a trigger nor it was due the table reference. The update was part of a stored proc and I was calling the db using linked server. It so happened that I was a readonly user on the other server.

 I sincerely appreciate your help in this regard.
ASKER CERTIFIED SOLUTION
Avatar of raGadiraju
raGadiraju

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial