|
-
Jul 20th, 2001, 09:28 AM
#1
Thread Starter
Addicted Member
Unix to Oracle help needed
I have a Unix script which calls sql*plus to run a sql script, I want the sql script to return the single value (a character eg "A") from a select statement.
the UNIX script does this:
sqlplus -s login/password @$sqlfile/sqlScrip.sql
ret_val=$?
and
the SQL script does this:
set heading off
whenever SQLERROR EXIT 99
REM Only a single value in this Table.
select STATUS
from TBLINTERFACE_MESSAGE;
exit
but all I manage to capture is the exit code from sql*plus (ie 0 not "A"), not the value returned from the SQL select
can anyone help?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|