Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: HowTo: Trigger for Change- Logging
Andreas Mosmann schrieb:
> if I insert the statement
> select
> program
> into
> lvsProgram
> from
> v$session
> where
> audsid=sys_context('USERENV','SESSIONID');
> i got the compiler error
> "ORA 00942: Table or View doesn't exist" at the position from "v$session"
> I tried v_$session but the same result.
> Outside of the trigger (that is owned by USERX) USERX can select
> v$session as well as v_$session.
> Must triggers be given any privilegs on v$session?
>
ORA 00942 error indicates very likely that you have not sufficient privileges. The ability to select from v$session is probably covered by the role, you need to grant as sys SELECT on v_$session to trigger owner. Triggers can not be granted any privileges, only to users and roles.
Best regards
Maxim Received on Thu Sep 15 2005 - 13:39:23 CDT