Running multiple SQLLDR command lines from one script
Posted on 2006-03-21
I have six csv files we need to load every morning. I've written a script to create dynamic control files for each file, since they have the current date in the file name. I'm now trying to run this script as well as the six sqlldr scripts from one script. The script executes and creates the six control files with no problem. It also runs the first sqlldr script but aborts after it completes. I'm guessing this is because of bad records. I want the bad records to write to the .bad file (it does) and continue on to the next sqlldr script. It just stops. We're VMS, Oracle 9205. I've tried silent=all and that had no affect. Here are the last lines before it aborts. I'm thinking this may be because of a VMS error message. Thanks in advance for your time.
Commit point reached - logical record count 3392
Commit point reached - logical record count 3439
%NONAME-E-NOMSG, Message number 00000002
Here's a portion of my script:
$@run_sqlldr_hnama.com -- ABORTS after this one
Here's the first script that aborts:
$ set verify
$ DATE == F$CVTIME("YESTERDAY",,"DATE")
$ show symbol DATE
$ YY == F$EXTRACT(2,2,DATE)
$ show symbol YY
$ MM == F$EXTRACT(5,2,DATE)
$ show symbol MM
$ DD == F$EXTRACT(8,2,DATE)
$ show symbol DD
$ MMDD = "''MM'''DD'"
$ show symbol MMDD
$ MMDDYY = "''MM'''DD'''YY'"
$ show symbol MMDDYY
$ sqlldr control=hnamaload'''MMDDYY'.ctl,log=hnamaload'''MMDDYY'.log, -
userid=sla/xxx, discard=hnamaload'''MMDDYY'.dis -