Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: SQL Loader automation
"John F. Keaveney" wrote:
> succedded or failed. The presence of a bad file is not enough of an
> Has anyone found
> an elegant way to monitor the results of SQL Loader in an automated
> fashion?
SQL Loader does return a non-zero exit code when it fails. Below is an chunk of the SQL Loader documentation. Unfortunately, the exit code are not very useful if you don't mind rows being rejected or discarded. SQL Loader returns the same code, EX_WARN, when it throws out a single row for bad formatting and when it runs out of tablespace and dies horribly. If you want to distinguish between those cases, you might try setting SILENT=(ALL) and looking for messages written to STDERR. That seems to seperate the petty discards from the catastrophic failures.
Steven
ExitCode
EX_SUCC All/some rows rejected EX_WARN All/some rows discarded EX_WARN Discontinued load EX_WARN Command line/syntax errors EX_FAIL Oracle errors fatal to SQL*Loader EX_FAIL OS related errors (like file open/close, malloc, etc.) EX_FTL
For UNIX the exit codes are as follows:
EX_SUCC 0 EX_FAIL 1 EX_WARN 2 EX_FTL 3Received on Thu Feb 25 1999 - 01:41:34 CST