Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Shell script to catch PL/SQL return values
Hello,
I need some help from the experts on PL/SQL and Shell scripting. I need a shell script that runs a PL/SQL procedure and gets the values returned from the PL/SQL procedure into the shell variables. The PL/SQL procedure returns multiple values.
I was able to assign a single return value from the SQL statement to the shell variable as below, but what about multiple values...
bash-2.05$ more shellsql.sh
#!/bin/ksh
#set -x
outvar=`sqlplus -s apps/apps <<EOF
set heading off feedback off verify off
select bug_number from ad_bugs where bug_number='4289310';
exit
EOF `
echo $outvar
Thanks for your help on this. Received on Tue Jun 27 2006 - 05:47:45 CDT