How do I call a shell script with 2 parameters
DBAsupport.com Forums - Powered by vBulletin
Results 1 to 2 of 2

Thread: How do I call a shell script with 2 parameters

  1. #1
    Join Date
    Mar 2002
    Posts
    25

    Question How do I call a shell script with 2 parameters

    How do I call a shell script that requires say 3 parameters $1, $2, $3?

    Basically, I have a shell script that I want certain users with valid password to use it. As the username and valid password will be the 3 parameters the script requires.
    Eg: I want to run the script (say test.sh) and pass the username and password (Scott/tiger@db) as a parameter.

    Can someone help please?

    Thanks..

  2. #2
    Join Date
    Dec 2001
    Location
    Keene, NH
    Posts
    510
    This book is a must have:
    http://www.bookpool.com/.x/pewws7tm4m/sm/1565924274

    There's also unix.com for unix forums.

    example:
    #!/bin/ksh
    sname=$1
    dname=$2

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Click Here to Expand Forum to Full Width