![]() |
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Shell Script And SQLPLUS | maco_home | UNIX for Dummies Questions & Answers | 6 | 08-25-2007 01:05 PM |
| calling sqlplus from within a for loop | akosz | Shell Programming and Scripting | 4 | 05-03-2007 03:23 PM |
| Problem while calling Oracle 10g SQLPLUS files | ganapati | UNIX for Advanced & Expert Users | 2 | 05-01-2007 04:03 AM |
| SQLplus in Shell scripts | trupti_d | Shell Programming and Scripting | 12 | 03-16-2007 09:46 AM |
| connect to sqlplus from shell | aya_r | Shell Programming and Scripting | 4 | 02-07-2007 05:52 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
calling sqlplus from shell
Hi All,
I am executing the following code :- sqlplus -s ${DATABASE_USER} |& print -p -- 'set feed off pause off pages 0 head off veri off line 500' print -p -- 'set term off time off serveroutput on size 1000000' print -p -- "set sqlprompt ''" print -p -- "SELECT run_command from tmp_run_batch where upper(batch_name) = upper('${PAR_PROGRAM_NAME}');" read -p RUN_COMMAND eval print -p -- \""execute dbms_output.put_line(${RUN_COMMAND});"\" read -p RET_VAL print -p -- "exit;" The select stmt given above gives sample output as :- pack_claims_clas_utils.func_main('$PAR_RUN_DATE','$PAR_RUN_LEVEL','$PAR_EXCLUSIVE_RUN_YN') And then this package is executed. The problem that I am facing is how to handle the no_data_found case of the select stmt. . When this case arises then the stmt. "read -p RUN_COMMAND" hangs. Could you please provide any solution ? Thanks Suds |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|