Hi,
I am executing sql files in my unix shell script. Now i want to find whether its a success or a failure record and redirect the success or failure to the respective files. meaning.
success records to success.log file
failure record to failure.log file.
As of now i am doing like this.
db3 connect to a
db3 connect to b
db2 -tvf "${var[Perforce_Script_Name]}" > $output
grep -v "successfully" "${var[Perforce_Script_Name]}" >suc_Logfile
grep -v "SQLSTATE" "${var[Perforce_Script_Name]}" >fail_Logfile
But i am not able to see any thing in those files. pls help me.
Thanks for your help and time.