The UNIX and Linux Forums  


Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com




View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #1 (permalink)  
Old 04-29-2008
ksmbabu ksmbabu is offline
Registered User
  
 

Join Date: Apr 2008
Location: Bangalore
Posts: 14
connecting to oracle thro informatica

Hi

I have a shell script which is running fine in unix. But if i call the shell script thro informatica workflow post session command task it is not giving me the sum(amount) to a output text file

The sql_configh.sh file has uid@db/pwd

script_path="/path"
cd $script_path

connstr=`grep "uid@db" $script_path/sql_config.sh`

touch $script_path/sum_cr_amt.txt
chmod 777 $script_path/sum_cr_amt.txt


sqlplus -s > $script_path/sum_cr_amt.txt <<eof1
$connstr
select round(sum (entered_cr),2) entered_cr from table_name
where trunc(date_created)='04-jan-2008';

eof1

x=$?

if [ x -ne 0 ]
then
exit 1
fi
exit 0

I need your gr8 help

Thanks
Babu