Toad World® Forums

Toad for Oracle 12.8 - Error while writing to audit trail


Hi all,

I am using Toad for Oracle 12.8 on two Oracle 11g environments - DEV and UAT. On DEV everything works perfect but on UAT when executing any query (select, update, delete - no matter) I get the following error.

ORA-02002: error while writing to audit trail
ORA-22923: amount of data specified in streaming LOB write is 0

There are two weird things:

  1. After the error, it still displays the result of the query.
  2. I tried using SQL developer, same login credentials and that does not give me any error.

Do you maybe have any suggestions what Toad is doing?



Short answer here is that auditing seems to be active on your UAT database, and Toad is doing you a favor by picking up this error, even though it’s not a Toad issue. Discuss this with your DBA. You may not need to have Auditing turned on, or there could be issues with the underlying audit tables/schema.



Thanks a lot for the answer.

Maybe not a a Toad issue but is there an SQL I can use to check Auditing status or settings on DEV vs UAT? Our DBs are outsourced and unless I spoonfeed the DBAs most probably they’ll tell me to use SQL Developer if I don’t like it …



I found the query below and when running it i found that I have 7 times the SELECT TABLE audit_option. Is this normal?

SELECT audit_option, success, failure FROM dba_stmt_audit_opts order by 1;



Just to let you know we found the problem - this is an issue in the Toad for Oracle 12.8 (maybe others) and by changing to a newer version solved it.


How did you (or support) determine that it was a Toad problem? I don’t recall ever doing anything to “fix” this in a prior version.

For what it’s worth, I set up unified auditing on an Oracle 12.2 database, then connected using Toad 12.8. Audit records were generated and there were no errors.