Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Oracle Odp.Net unreported error on call to procedure in invalid package

I just got my worst maintenance nightmare : a silent error.

I was calling a procedure using Odp.Net inside a custom package, and the procedure call failed silently without any exception being thrown (verified using both step by step debug and a catch all clause). After much searching I noticed that the Package was invalidated (some mishap on the server), after recompiling the package everything was back to normal (the call code was correct and unmodified).

Since it is really easy to invalidate a package accidentally in Oracle, I need to catch this kind of error, if only to log them for debugging.

With MS's System.Data.OracleClient an OracleException was thrown in this case, is there any way to get a similar behavior with Oracle's Oracle.DataAccess ? Some kind of sqlnet.ora parameter ? I found no similar problem anywhere on the net.

using Oracle11R2 server, latest Oracle Win32 client. .Net3.5.

like image 748
Michel Avatar asked Nov 05 '22 03:11

Michel


1 Answers

Have you tried enabling odp.net trace log?

<oracle.dataaccess.client>
  <settings>
   <add name="TraceFileName" value="c:\odpnet1.trc"/>
   <add name="TraceLevel" value="63"/>
 </settings>
 </oracle.dataaccess.client>

Maybe it will shed some light?

like image 155
Peter C Avatar answered Nov 09 '22 13:11

Peter C