![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
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 |
| ssh - passing password in shell script | Muktesh | Shell Programming and Scripting | 5 | 05-05-2009 12:37 PM |
| passing values from sql to shell script | sachin.gangadha | Shell Programming and Scripting | 3 | 04-22-2008 11:11 PM |
| Passing arguments to a shell script from file while scheduling in cron | weblogicsupport | SUN Solaris | 4 | 01-27-2008 11:16 PM |
| passing two variables into a shell script? | Bashar | Shell Programming and Scripting | 2 | 05-15-2007 10:00 AM |
| passing awk variable to the shell script | bcheaib | Shell Programming and Scripting | 3 | 07-21-2004 10:00 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
I have a shell script which takes at the command prompt options like
ss1.sh -F SCOTT -T JOHN F- From User T- To User I want to pass the From User(SCOTT) Value to another script ss2.pls (This script runs a PL/SQL Program). Depending on the FromUser value in the ss1.sh script i have to code accordingly in the ss2.pls script. How can i pass the FromUser Value in the ss1.sh to ss2.pls script. Exec Sequence: First ss1.sh script is run then ss2.pls is run. Thanks ! Last edited by dreams5617; 11-29-2004 at 12:36 PM.. |
|
||||
|
I have a shell script which takes at the command prompt options like
ss1.sh -F SCOTT -T JOHN F- From User T- To User Inside the ss1.sh there is a call to ss2.sh(inside this shell script there is a call to proced.pls, in this program(proced.pls) i have to pass the T -Touser value from the ss1.sh shell script). Ex: vi ss1.sh { Function() { /db2/home/ss2.sh $ORACLE_SID } } vi ss2.sh { sqlplus -s / as sysdba << ! set verify off @/db2/home/proced.pls } vi proced.pls { declare cursor sym_owner is select owner from all_synonyms where owner=UPPER('$ToUser'); -- I want the value of ToUser taken -- from ss1.sh script here in the SQL -- statement. ..........................................................................etc } ss2.pls (This script runs a PL/SQL Program). Depending on the ToUser value in the ss1.sh script i have to code accordingly in the ss2.pls script. How can i pass the ToUser Value in the ss1.sh to ss2.pls script. Thanks ! red red red |
|
|||||
|
I have merged this with the thread you started when you asked the same question several days ago. Please read the rules particularly the ones regarding bumping posts and cross/duplicate posting.
Why can't you just do something along the lines of Code:
$ cat > ss1.sh #!/bin/sh touser=$1 ss2.sh $touser ^D $ cat > ss2.sh #!/bin/sh echo "Inside ss2.sh> $1" ^D $ chmod +x ss1.sh $ chmod +x ss2.sh $ ./ss1.sh foouser Inside ss2.sh> foouser Cheers ZB |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|