By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,742 Members | 773 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,742 IT Pros & Developers. It's quick & easy.

HELP!! errors managing. i need help.

P: 7
hi to everybody!!
i wrote i script from Unix's Bourne shell that connects to an Oracle DataBase and calls a Stored Procedure. Now i'd like to insert some more commands for error managing.
here's my scritp:

stty istrip
stty erase ^H
export ORACLE_BASE=/product/oracle
export ORACLE_HOME=$ORACLE_BASE/product/9.2.6
export PATH=$ORACLE_HOME/bin:/usr/ccs/bin:/bin:/usr/bin:/usr/local/bin:/usr/ucb:/tibcosv/dtsgvemi/S2T/scripts
sqlplus USER/PASSWORD@(DESCRIPTION =(ADDRESS_LIST =(ADDRESS = (PROTOCOL = TCP)(HOST = IP_ADDRESS)(PORT = PORT_number)))(CONNECT_DATA =(SID = sid_name))) @chiamata_errore
exit

and here's the chiamata_errore.sql:

spool PROVA_3.log
exec PROVA_3;
whenever sqlerror exit 1
whenever oserror exit 1
spool off
exit

What can i add more on these 2 scripts in case of errors?
connection errors
stored procedure calling errors
etc

And how can i creat a log file for all these errors?
thank you
Nov 3 '06 #1
Share this question for a faster answer!
Share on Google+

Post your reply

Sign in to post your reply or Sign up for a free account.