Home » SQL & PL/SQL » SQL & PL/SQL » using dyanamic performance tables in functions and procs
using dyanamic performance tables in functions and procs [message #272090] Thu, 04 October 2007 00:35 Go to next message
sanoj_av
Messages: 2
Registered: October 2007
Location: Bangalore
Junior Member
hi all,
when I query dyanamic performance tables like v$session,v$mystat etc. in Function I get an error (ORA-00942: table or view does not exist),But the same works fine in anonymous block.I am having the DBA Privilege also.
Can anyone give any idea regarding this.....?


Regards,
Sanoj
Re: using dyanamic performance tables in functions and procs [message #272093 is a reply to message #272090] Thu, 04 October 2007 00:41 Go to previous messageGo to next message
BlackSwan
Messages: 25033
Registered: January 2009
Location: SoCal
Senior Member
Privs acquired via ROLE do not apply within PL/SQL procedure
Re: using dyanamic performance tables in functions and procs [message #272146 is a reply to message #272093] Thu, 04 October 2007 02:15 Go to previous message
sanoj_av
Messages: 2
Registered: October 2007
Location: Bangalore
Junior Member
I did not have permission on the v_$session,v_$mystat base tables. Now it is working.

Thank you,
Sanoj
Previous Topic: Selecting data from a Package that returns a Table Set
Next Topic: Extracting undo/redo via logminer for one specific transaction?
Goto Forum:
  


Current Time: Fri Dec 02 16:55:37 CST 2016

Total time taken to generate the page: 0.08198 seconds