Xref: alice comp.databases.oracle.server:74455
Path: alice!news-feed.fnsi.net!newsfeed.icl.net!dispose.news.demon.net!demon!news.demon.co.uk!demon![212.240.122.170]!not-for-mail
From: "Reza" <reza@digital-dispatch.co.uk>
Newsgroups: comp.databases.oracle.server
Subject: Re: Executing a SQL from svrmgr from command line
Date: Wed, 17 Nov 1999 18:48:34 -0000
Message-ID: <942864589.23929.0.nnrp-04.d4f07aaa@news.demon.co.uk>
References: <942861734.224930@sj-nntpcache-2.cisco.com>
X-Trace: news.demon.co.uk 942864589 nnrp-04:23929 NO-IDENT [212.240.122.170]:212.240.122.170
X-Complaints-To: abuse@demon.net
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 5.00.2314.1300
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2314.1300
Lines: 43

Parveen
You can try
=======================
TMP= <os. filename>
TMPX= <os. filename>
SCRIPTFILE    = <sql script file>
svrmgrl <<EOF >> $TMP
set echo on
spool $TMPX
connect internal
@ $SCRIPTFILE    -- or any other in-line sql or plsql proc.

exit
EOF
cat $TMPX
=============================
Regards
Reza

Praveen Mohanan <praveen_mohanan@hotmail.com> wrote in message
news:942861734.224930@sj-nntpcache-2.cisco.com...
> TO DBA GURUS,
>
>
>    I wanted to execute one few commands from the command line & exit at
the
> end. For eg
>
> 1. invoke srvmgr
> 2. connect internal
> 3. run a SQL script
> 4. exit
>
> How can i write this in a shell script, so that if i call the shell, it
will
> run all these command & come back to the prompt.
>
>
> Regards
>
>


