Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> Re: Beyond a basic Oracle EXP/IMP shell script: Error Handling & Exit Status?

Re: Beyond a basic Oracle EXP/IMP shell script: Error Handling & Exit Status?

From: Michael McMullen <ganstadba_at_hotmail.com>
Date: Fri, 19 Aug 2005 09:05:42 -0400
Message-ID: <BAY103-DAV2087AE52C7541F0CF8701A6B50@phx.gbl>


Beyond a basic Oracle EXP/IMP shell script: Error Handling & Exit Status?You used this one yet for exp?

grep "without warnings" ${LOG_FILE} > /dev/null 2>&1

   if [ $? != 0 ]
   then

      mailx -s "Failure in ${LOG_FILE}" ${MAILLIST} < ${LOG_FILE}    fi

need to have statistics=none in your parameter file or you'll get an error. i don't know if error checking on imp is required. there are so many errors that could arise that reviewing the logfile might be the only check. but that doesn't mean you couldn't check for file existence etc.

Mike
----- Original Message -----
From: Marquez, Chris
To: oracle-l_at_freelists.org
Sent: Thursday, August 18, 2005 4:14 PM
Subject: Beyond a basic Oracle EXP/IMP shell script: Error Handling & Exit Status?

All,

OK, OK, OK...my task (specifically).
1.) I need to know (or test) if my script completes successfully and assign a value.

2.) I need to know if/where my script dies/aborts/terminates in the middle and assigning a value....rolling variable?

     "if step A complete then v_stats=...if step B complete then v_stats=..."

3.) I need to get a positive or negative return code from Oracle EXP/IMP utility and pass it to shell script (#2 above).

I'm all ears...and ready for code samples-scripts, docs, links and references.

Thanks,

Chris Marquez
Oracle DBA

--
http://www.freelists.org/webpage/oracle-l
Received on Fri Aug 19 2005 - 08:07:52 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US