April 6, 2005 at 10:50 am
I have a table called DISPOSITION_TABLE that has data loaded into it and it can be queried fine in Enterprise manager. I tried to grant permissions to users using Enterprise manager but they do not seem to take effect. I tried applying permissions in Query Analyzer using
GRANT SELECT,INSERT,UPDATE
ON DISPOSITION_TABLE
TO Expl_Web_user
GO
but this led to the following message
Invalid object name 'DISPOSITION_TABLE'.
so I tried refering to the table as dbo.DISPOSITION_TABLE and got
Invalid object name 'dbo.DISPOSITION_TABLE'.
when I try Database1.dbo.DISPOSITION_TABLE I get
You can only grant or revoke permissions on objects in the current database.
Why is my table an Invalid object name ?
How can I set the current database in Query Analyzer so I can do this?
Thanks for any help you can provide.
April 6, 2005 at 11:21 am
There are a couple ways to set the current database in QA. First, there is a drop down box in the menu bar at the top. Simply select the db that you want. Or, in your query window, just type "USE MYDB" where "mydb" is the name of your database. That will change the focus within your query.
Now, to your object name problem. Is dbo the owner of the object???? In query analyzer, find the object and check the owner. If it is anything other than dbo, then that id must be used to identify the object, ie 'joe_user.joes_table'.
Steve
Viewing 2 posts - 1 through 1 (of 1 total)
You must be logged in to reply to this topic. Login to reply