From oracle-l-bounce@freelists.org Thu Sep 1 16:35:13 2005 Return-Path: Received: from air891.startdedicated.com (root@localhost) by orafaq.com (8.12.10/8.12.10) with ESMTP id j81LZDsW016033 for ; Thu, 1 Sep 2005 16:35:13 -0500 X-ClientAddr: 206.53.239.180 Received: from turing.freelists.org (freelists-180.iquest.net [206.53.239.180]) by air891.startdedicated.com (8.12.10/8.12.10) with ESMTP id j81LZAIP016019 for ; Thu, 1 Sep 2005 16:35:11 -0500 Received: from localhost (localhost [127.0.0.1]) by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTP id 1EAB61E8CB4; Thu, 1 Sep 2005 16:33:10 -0500 (EST) Received: from turing.freelists.org ([127.0.0.1]) by localhost (turing [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 19421-09; Thu, 1 Sep 2005 16:33:10 -0500 (EST) Received: from turing (localhost [127.0.0.1]) by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTP id 917921E8B35; Thu, 1 Sep 2005 16:33:09 -0500 (EST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:from:to:references:subject:date:mime-version:content-type:x-priority:x-msmail-priority:x-mailer:x-mimeole; b=IYrVBpePcr4pvszqGYI9fNVojFPgyZH7AVAdnrlczFIJ6Ajz6uugUW3y4+IIlF+njIBixU60hJMbPg4ico+tc4HNbBTu7AqPaU9cu9O2kSzmT5hERYmNx8d36lNFdTmj2UyH84sEi596lC+ybWkWUIlYEfCUfEZRJ4bJ3Ux2cgs= Message-ID: <01be01c5af3c$7af5e100$2408310a@IBME1D11967173> From: "Radoulov, Dimitre" To: "Marquez, Chris" , References: Subject: Re: PART II: - Beyond a basic Oracle EXP/IMP shell script: Error Handling & Exit Status? Date: Thu, 1 Sep 2005 23:31:11 +0200 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_01BB_01C5AF4D.3CF307F0" X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2670 X-archive-position: 24935 X-ecartis-version: Ecartis v1.0.0 Sender: oracle-l-bounce@freelists.org Errors-To: oracle-l-bounce@freelists.org X-original-sender: cichomitiko@gmail.com Precedence: normal Reply-To: cichomitiko@gmail.com X-list: oracle-l X-Virus-Scanned: by amavisd-new-20030616-p9 (Debian) at avenirtech.net X-mailscan-MailScanner-Information: Please contact the ISP for more information X-mailscan-MailScanner: Found to be clean X-MailScanner-From: oracle-l-bounce@freelists.org X-Spam-Level: X-Spam-Checker-Version: SpamAssassin 2.63 (2004-01-11) on air891.startdedicated.com X-Spam-Status: No, hits=-4.3 required=5.0 tests=AWL,BAYES_00,HTML_MESSAGE autolearn=ham version=2.63 ------=_NextPart_000_01BB_01C5AF4D.3CF307F0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable RE: PART II: - Beyond a basic Oracle EXP/IMP shell script: Error = Handling & Exit Status?It's the RC's variable value(not the return code, = but the entire command output). Look at the second one ... a) $ export_simple_script.sh > /dev/null 2>&1 ; RC=3D$?; echo $RC 1 b) $ RC=3D`export_simple_script.sh` > /dev/null 2>&1 ; echo $RC Export: Release 9.0.1.5.0 - Production on Thu Sep 1 23:28:21 2005 (c) = Copyright 2001 Oracle Corporation. All rights reserved. EXP-00056: = ORACLE error 1034 encountered ORA-01034: ORACLE not available ORA-27101: = shared memory realm does not exist SVR4 Error: 2: No such file or = directory EXP-00005: all allowable logon attempts failed EXP-00000: = Export terminated unsuccessfully RETURN CODE: Set next Return Code - RC: = ORACLE EXP RETURN CODE. 1 ORACLE EXPort FAILED!: 1 Cheers, Dimitre Radoulov ------=_NextPart_000_01BB_01C5AF4D.3CF307F0 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable RE: PART II: - Beyond a basic Oracle EXP/IMP shell = script: Error Handling & Exit Status?
It's the RC's variable value(not the = return code,=20 but the entire command output). Look at the second one ...
 
a)
 
$ export_simple_script.sh > = /dev/null=20 2>&1 ; RC=3D$?; echo $RC
1
 
b)

$ RC=3D`export_simple_script.sh` = > /dev/null=20 2>&1 ; echo $RC
Export: Release 9.0.1.5.0 - Production on Thu = Sep 1=20 23:28:21 2005 (c) Copyright 2001 Oracle Corporation. All rights = reserved.=20 EXP-00056: ORACLE error 1034 encountered ORA-01034: ORACLE not available = ORA-27101: shared memory realm does not exist SVR4 Error: 2: No such = file or=20 directory EXP-00005: all allowable logon attempts failed EXP-00000: = Export=20 terminated unsuccessfully RETURN CODE: Set next Return Code - RC: ORACLE = EXP=20 RETURN CODE. 1 ORACLE EXPort FAILED!: 1
 
 
 
Cheers,
Dimitre = Radoulov
 
 
------=_NextPart_000_01BB_01C5AF4D.3CF307F0-- -- http://www.freelists.org/webpage/oracle-l