Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.tools -> get the SQL that raised an error.
Hello,
I'ld like to get the command that raised an error to stock it in an alert
table, I don't know which view or table to use for that, I tried with :
SELECT sql_text
FROM v$sqltext
WHERE (address, hash_value) IN
(SELECT sql_address, sql_hash_value FROM v$session WHERE audsid = userenv('SESSIONID')) order by piece;
But if I run that I get the select that I'm currently executing (SELECT sql_text FROM v$sqltext...).
How can I do to get the previouse command and not the current one or even better the exact one that raised an error ?
Thanks in advence,
Youtz.
Received on Wed Aug 08 2001 - 08:21:59 CDT