By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,592 Members | 1,958 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,592 IT Pros & Developers. It's quick & easy.

Cannot read from sys.v_$session

P: n/a
I have done the following as dbo:

grant select on sys.v_$session to dbo;
create or replace view z as select * from sys.v_$session ;

But the second command gives me:
ERROR at line 1:
ORA-00942: table or view does not exist

I can select directly from sys.v_$session by
select * from sys.v_$session;

What do I have to do/grant permission wise to be able to create a view
or PL/SQL function which accesses sys.v_$session?

Regards
Chris (ch********@msn.com)
Jul 19 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
ch********@msn.com (Chris Jack) wrote in message news:<64**************************@posting.google. com>...
I have done the following as dbo:

grant select on sys.v_$session to dbo;
create or replace view z as select * from sys.v_$session ;

But the second command gives me:
ERROR at line 1:
ORA-00942: table or view does not exist

I can select directly from sys.v_$session by
select * from sys.v_$session;

What do I have to do/grant permission wise to be able to create a view
or PL/SQL function which accesses sys.v_$session?

Regards
Chris (ch********@msn.com)


Because as the procedure or view owner you can grant access to your
object to others, but because you reference objects owned by third
parties you must have a direct grant on the foreign object and have
the avility to grant access to others (with grant option). See the
DBA Administration manual and SQL manual sections on managing object
privileges.

HTH -- Mark D Powell --
Jul 19 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.