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

Home -> Community -> Usenet -> c.d.o.server -> Re: How to avoid display of password when script executes SQLPLUS / SQLLDR

Re: How to avoid display of password when script executes SQLPLUS / SQLLDR

From: Anurag Minocha <anurag_at_synergy-infotech.com>
Date: Fri, 03 Sep 1999 14:24:30 +0530
Message-ID: <37CF8CC6.23F60422@synergy-infotech.com>


how do we do the same on an NT machine ?

Thanks
anurag

also reply at
anurag_at_synergy-infotech.com

benryan_at_my-deja.com wrote:

> In article <37CDA7A8.18BB_at_wxs.nl>,
> goei <goei_at_wxs.nl> wrote:
> > Hi all,
> >
> > I don't know if i'm in the right group and if not sorry.
> >
> > My problem is the following:
> >
> > Is it possible to execute a Unix Script including calling SQLPLUS with
> > its parameters (Database-name and Password) but without having the
> > password displayed when one uses the Unix PS (Processor Statistics?)
> > Command? Maybe there are other Unix Commands which shows Password too.
>
> I normally use the following template for Unix shell scripts.
>
> {
> echo "Username: \c" ; read user
> echo "Password: \c"; stty -echo; read pass; stty echo; echo
> } > /dev/tty
> sqlplus -s <<EOF
> $user/$pass
> set feedback off
> set pagesize 0
> SELECT SYSDATE FROM dual;
> EOF
>
> If you want to check that you cannot see the password from ps, replace
> the SELECT ... FROM dual statement with something that takes a long
> time. (E.g. anonymous PL/SQL block that counts to, say, a million.)
>
> >
> > The same applies for calling SQLLDR.
>
> Same plot. Do not put the USERID directive in the command line and
> sqlldr will prompt you for the username and password.
>
> sqlldr CONTROL=whatever.ctl <<EOF
> $user/$pass
> EOF
> >
> > Thank you all very much.
> >
> > G. Oei
> >
>
> Sent via Deja.com http://www.deja.com/
> Share what you know. Learn what you don't.
Received on Fri Sep 03 1999 - 03:54:30 CDT

Original text of this message

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