carriage return
Hi there,
I'm writing a script that logs into the oracle db, execute a command "recover standby database;", then the command prompts the user to enter a value such as "auto" before the command can be executed. Below is my script, but it is not performing the actions I wanted. Thanks in advance #!/bin/bash sqlplus / as sysdba <<CMD recover standby database; auto <<EOF exit; EOF CMD |
Hmm.. I guess you can't nest files in files.
|
Quote:
The script you are writing hasn't the remotest chance of giving you what you want, regardless of what you want, which you don't specify. |
Try the following:
1. Create a file called cmd.sql and add the following lines: recover automatic standby database until cancel; exit; 2. Modify your Bash shell script to read as follows: #!/bin/bash sqlplus / as sysdba @cmd.sql I hope that this does the trick for you. Good luck. Shahriar. |
All times are GMT -5. The time now is 05:29 AM. |