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

Home -> Community -> Mailing Lists -> Oracle-L -> slightly ot: nohup disables echo?

slightly ot: nohup disables echo?

From: Barbara Baker <barbarabbaker_at_yahoo.com>
Date: Thu, 26 Feb 2004 08:58:16 -0800 (PST)
Message-ID: <20040226165816.80316.qmail@web14424.mail.yahoo.com>


Hi, list!
Solaris 9 Oracle 9.2.0.4
Is there something about nohupping a script that will cause "set echo" in sqlplus to not work?

I'm trying to load a bunch of tables, and I'd like to run them in background. When I run the script in sqlplus, I see all my output (including the time stamps, which I really need.)
When I run in background, the ".lis" file is missing the timestamps.

Am I missing something obvious?

Here's a quick kludge that should show what I'm going. Thanks for any help.
Barb

nohup /oracle/gather.sh 1> /oracle/gather.log &

=====> gather.sh:

#!/bin/ksh
#set the environment
. /oracle/set_ent9i.sh
sqlplus -s user/pwd << EOF
set echo on
spool gather_one_table.lis
select name from v\$database;
@gather_one_table.sql
exit
EOF
=====>gather_one_table.sql:

SET SERVEROUTPUT ON SIZE 1000000
SET FEEDBACK 1
SET TIME ON
SET ECHO ON HOST date
SPOOL gather_one_table.lis

exec dbms_stats.gather_table_stats -

        ( ownname=> 'ADVDB',        -
          tabname => 'XMLS_HIERARCHY',    -
          cascade => TRUE          -
          );

HOST date
exit

=====> gather_one_table.lis output:

$> more gather_one_table.lis

PL/SQL procedure successfully completed.



Do you Yahoo!?
Get better spam protection with Yahoo! Mail. http://antispam.yahoo.com/tools

Please see the official ORACLE-L FAQ: http://www.orafaq.com

To unsubscribe send email to: oracle-l-request_at_freelists.org put 'unsubscribe' in the subject line.
--
Archives are at http://www.freelists.org/archives/oracle-l/
FAQ is at http://www.freelists.org/help/fom-serve/cache/1.html
-----------------------------------------------------------------
Received on Thu Feb 26 2004 - 10:58:44 CST

Original text of this message

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