I have a ksh shell script that runs a .sql script with a background and wait statement. Is it possible for me to capture the generic "ORA-0" error and exit out completely?
So far:
$ORACLE_BASE/bin/sqlplus 2.sql &
pid2=$!
echo "Waiting for PID:$pid2"
wait $pid2
#look for error here
#exit program if oracle error