Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.tools -> Re: PROC C/C++ Get Last SQL Statement
Johan,
I always trap errors individually in Pro*C programs by performing a switch on the sqlcode (rather than use WHENEVER clause). This gives me far more control over error trapping, but does increase the size of the source code (but lets me decide exactly what is an error - multiple rows ok etc.). In this way, I can supply a list of the bind variables and their contents to my error handler. Alternatively (less preferred), you could define a global variable which holds the contents of all bind variables which could be used in your error handling routine. Assign these values BEFORE you make your SQL call.
-- Jim Harrison Colway Software and Design www.colway.freeserve.co.ukReceived on Sat Apr 29 2000 - 00:00:00 CDT
![]() |
![]() |