There are few shell scripts that use the isql to execute some sql statements on a Sybase database server. I see several Log Suspend messages in the logs and the problem is that the shell script exits with success.
The transaction log in database MAIN_DB is almost full. Your transaction is being suspended until space is made available in the log.
I need to intercept these Log suspend messages and report the correct error. How do I do this? I am not sure about how to proceed here. When it occurs there is no way it gets cleared and the database administrator has to kill the spid after a some time, but the script already exits with success. So, the data-transfer didn't actually happen and was aborted. This is the scenario I need to handle.
Please let me know how we would be able to intercept the Log Suspend and atleast wait for a particular time ?
Server Details (
"Adaptive Server Enterprise/12.5.4/P/x86_64/Enterprise Linux/ase1254/2159/64-bit/OPT/Mon Nov 2 03:14:39 2009"