BrianTyler
IS-IT--Management
In AIX scripts I use:
print "Job Start" > $LOGFILE
db2 -t -s +v +p connect to $DB2DBDFT ;
db2 -t -s +v -x -z$REPFILE +p <<SQL >> $LOGFILE;
Select col1,col2 ... from table
;
SQL
print "Job Complete" >> $LOGFILE
This usually works fine, but sometimes DB2 doesn't stop at the correct point but tries to use the final print command as more sql, and gives me:
DB21007E End of file reached while reading the command
Is this an AIX problem or a DB2 problem ?
print "Job Start" > $LOGFILE
db2 -t -s +v +p connect to $DB2DBDFT ;
db2 -t -s +v -x -z$REPFILE +p <<SQL >> $LOGFILE;
Select col1,col2 ... from table
;
SQL
print "Job Complete" >> $LOGFILE
This usually works fine, but sometimes DB2 doesn't stop at the correct point but tries to use the final print command as more sql, and gives me:
DB21007E End of file reached while reading the command
Is this an AIX problem or a DB2 problem ?