Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Recording Logon and SQL

Re: Recording Logon and SQL

From: Burton Peltier <burttemp1REMOVE_THIS_at_bellsouth.net>
Date: Sun, 6 Jul 2003 01:09:11 -0500
Message-ID: <LSONa.11231$z34.1596@fe04.atl2.webusenet.com>


New triggers introduced in Oracle8i version (I think) would probably do it.

I know you can create an "after logon" trigger that could capture some info, but I am not sure if possible to track every sql statement . I know in Oracle9i there were new capabilities to allow tracking other things.

Anyway, look up command "create trigger" with options "After Logon on Database" for a start...

Fyi... we use the logon/logoff triggers to capture session length, DB user, OS user, ip address, program name, and client machine name.

The logon trigger does the insert to a table and the logoff updates the row with logoff date/time. We also move the records out of the table these 2 triggers hit into another table, daily. The 2nd table has indexes and is queried for reporting . But, only the logon/logoff triggers touch the 1st table which has no indexes (didn't want to slow down logon/logoff process).

-- 
"netnews.comcast.net" <jglickma_at_lynx.neu.edu> wrote in message
news:N%JNa.16492$Ix2.8148_at_rwcrnsc54...

> Does anybody know of a way to track every user
> and SQL statement from the v$session and
> v$sqlarea without using auditing. Currently we are using
> a stored procedure that polls these tables but sometimes
> the pool is flushed allowing statements to slip in between the cracks.
> Looking for a better way of doing this.
>
>
>
>
>
Received on Sun Jul 06 2003 - 01:09:11 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US