Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Using variable withing shell scripts for calling Oracle DB procedures
swapandutta_at_yahoo.com (Swapan Dutta) wrote in
news:d220f943.0109261714.3fe7768a_at_posting.google.com:
> Hello :
> I want to pass variables to oracle procedures.
> I tried the following script, but it failed.
>
> ---------------------------
> #!/bin/sh
> first_var='value'
> sqlplus -s username/password_at_connect <<END
> execute package.proc($first_var,'two','three');
> END
>
> exit 0
> ---------------------------
>
> If I replace $first_var in the execute statement by a static string,
> the script works. What is the syntax for passing variables within
> shell script to oracle procedure?
>
> Thanks in advance.
>
> - Swapan.
![]() |
![]() |