Hi all,
I have a problem in running shell script, that uses sqlplus command, using the crontab.
Here is the script
#!/bin/ksh
export ORACLE_HOME
ORACLE_HOME=/oracle
export PATH
PATH=$PATH:$ORACLE_HOME:
izbor1=`$ORACLE_HOME/bin/sqlplus -s sti/sti <<end
set pagesize 0 feedback off ver off heading off echo off
select count (*) as " no" from Table where no = 1;
exit;
end`
..................
When I run the crontab at desired time the following output is shown
izbor1=ERROR: ORA-01034: ORACLE not available
ORA-07200: slsid: oracle_sid not set.
What's wrong with the script?
What else should I put?
Any suggestion would be helpfull.
GuzaPasha
I have a problem in running shell script, that uses sqlplus command, using the crontab.
Here is the script
#!/bin/ksh
export ORACLE_HOME
ORACLE_HOME=/oracle
export PATH
PATH=$PATH:$ORACLE_HOME:
izbor1=`$ORACLE_HOME/bin/sqlplus -s sti/sti <<end
set pagesize 0 feedback off ver off heading off echo off
select count (*) as " no" from Table where no = 1;
exit;
end`
..................
When I run the crontab at desired time the following output is shown
izbor1=ERROR: ORA-01034: ORACLE not available
ORA-07200: slsid: oracle_sid not set.
What's wrong with the script?
What else should I put?
Any suggestion would be helpfull.
GuzaPasha