Re: connect userid/password script

From: Marek Wiechula and Sheila Plant <sparemgw_at_batelco.com.bh>
Date: 1996/09/10
Message-ID: <3234B162.6C59_at_batelco.com.bh>#1/1


Daryl Peh Boon Chai wrote:
>
> You can store the password in a password file.
> Then in your sqlplus command, redirect in the password file, eg :
> sqlplus userid _at_sqlfilename < passwordfile
> This way, the password file can be kept in a safe place where only
> the CRON id can access. It is safer than keeping in the sqlscript.
>
> Daryl

You're right. It is safer to keep the password separately as you suggest. And actually I do store the password in a separate file, readable only by the oracle unix user. I don't generally use the file directly as you've shown, I prefer to extract the password into a unix variable which I later embed in the temporary sql script.

While we're on the subject, I also make sure that the temporary sql file is also unreadable for non-oracle users and I use a trap command to get rid of the file when I'm done with it.

I also capture the output of the sqlplus run and analyze it for ORA- type error messages. This allows me to distinguish between the case in which the data simply was not found and the case in which (for example) the database was simply not up and running.

Marek Received on Tue Sep 10 1996 - 00:00:00 CEST

Original text of this message