Thursday, February 16, 2012

cannot select from INFORMATION_SCHEMA views

On a SQL200 server, connected as sa, I am trying to select
from the INFORMATION_SCHEMA views, but I get an error
message indicating an invalid object. However, if I use
Enterprise Manager (registered as sa) to look at the views
in the master database, I can see the views and they show
they are owned by INFORMATION_SCHEMA. I've verified that
the public group has SELECT permissions to the views. Any
ideas, anyone?Sean Hokanson (shokanson@.sandlot.com) writes:
> On a SQL200 server, connected as sa, I am trying to select
> from the INFORMATION_SCHEMA views, but I get an error
> message indicating an invalid object. However, if I use
> Enterprise Manager (registered as sa) to look at the views
> in the master database, I can see the views and they show
> they are owned by INFORMATION_SCHEMA. I've verified that
> the public group has SELECT permissions to the views. Any
> ideas, anyone?
What exact statement are you using?
Erland Sommarskog, SQL Server MVP, sommar@.algonet.se
Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techinfo/productdoc/2000/books.asp|||Sean Hokanson (shokanson@.sandlot.com) writes:
>>What exact statement are you using?
> select * from INFORMATION_SCHEMA.KEY_COLUMN_USAGE
That seems to work here. What exact error message do you get?
--
Erland Sommarskog, SQL Server MVP, sommar@.algonet.se
Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techinfo/productdoc/2000/books.asp

No comments:

Post a Comment