Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

using the "oraenv" command w/out prompt 1

Status
Not open for further replies.

biot023

Programmer
Nov 8, 2001
403
GB
Hallo.
I need to use the "oraenv" command in a script that I wish to run with cron.
The problem is that when I use it, it offers me the following prompt:
ORACLE_SID = [gis] ?

Is there any way I can get rid of this prompt?
Thanks for any & all help.
Cheers,
Douglas JL.

A salesman is a machine for turning coke into obnoxious arrogance.

Common sense is what tells you the world is flat.

 
Hi,

On top of your script put something like:

ORACLE_SID=TOP export ORACLE_SID
ORAENV_ASK=NO
. oraenv
unset ORAENV_ASK

dbase77
 
That looks great, man, cheers.
Could I impose a little more & ask what it's doing?
It's a big machine & I get quite nervous!
Thanks again,
DJL

A salesman is a machine for turning coke into obnoxious arrogance.

Common sense is what tells you the world is flat.

 
Damn'! Doesn't seem to work.
In fact it prompted me twice! Once to confirm the TOP, and once to confirm the oracle home.
BTW - on the machine I'm on, the command "oraenv" doesn't work with a dot in front of it - does anyone know why this might be?
Cheers,
DJL

A salesman is a machine for turning coke into obnoxious arrogance.

Common sense is what tells you the world is flat.

 
Hi,

First of all, dont use "TOP" as oracle sid. Use your own oracle sid. "TOP" is just an example. Second of all are you using ksh shell or what?

dbase77
 
Ah, right.
I thought TOP was maybe the first element in a list of possible ORACLE_SID values or... I've no idea, really.
Thanks again,
DJL

A salesman is a machine for turning coke into obnoxious arrogance.

Common sense is what tells you the world is flat.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top