You can use the Auditing feature, onaudit. This audits just about anything
you want, by specific users as well. Only, it doesn't show you the actuall
SQL statement executed, just the table Id and row Id effected, and whether
it was an update, delete, etc.. You can also use the sysmater database and
select from syssqlcurses table. ie.
select scs_sqlstatement
from syssqlcurses, sysuserthreads
where scs_sessionid = us_sid
and us_name = "username"
However, this may not pick up every query, even if ran continuously, because
it takes a bit to pull the data from the system; some queries will have
already come and gone.
I too would like to know if there really is a way to capture every sql
statement of a user.
Don.
-----Original Message-----
From: fprose@my-dejanews.com [mailto:fprose@my-dejanews.com]
I've used the "onstat -g sql xxx' statement to view the last sql statement
issued by a user. Does anyone have a suggestion or know of a way to run a
complete trace on a specific user?
-----------== Posted via Deja News, The Discussion Network ==----------
http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own