DBAsupport.com Forums - Powered by vBulletin
Results 1 to 5 of 5

Thread: Problem executing SQL script within Unix

  1. #1
    Join Date
    Mar 2001
    Posts
    26
    Hi guys,

    I've tried numerous combinations to execute a script in SQL*PLUS within the Solaris environment. Unfortunately, nothing worked. On Windows it works fine.

    For example, I have a script call test.sql located in /tmp/dbscripts directory. When I start up SQL*PLUS in Solaris and run the following statement:

    SQL> @/tmp/dbscripts/test.sql

    ...it doesn't work. I keep getting 'unable to open file'

    What is the proper way to execute a script within the Unix environment?

    Thanks,
    - Gary

  2. #2
    Join Date
    Nov 2000
    Location
    greenwich.ct.us
    Posts
    9,092
    That should work. Do you have appropriate permission on that file?

    ls -l /tmp/dbscripts/test.sql
    Jeff Hunter

  3. #3
    Join Date
    Mar 2001
    Posts
    26
    The perfmissions were right, the spelling was wrong. Apparently, Unix wants EXACT spelling.

    What a pain!

    Thanks.
    - Gary

  4. #4
    Join Date
    Nov 2000
    Location
    greenwich.ct.us
    Posts
    9,092
    Originally posted by gshaf
    Apparently, Unix wants EXACT spelling.
    computers are funny like that...
    Jeff Hunter

  5. #5
    Join Date
    Mar 2001
    Posts
    188

    Wink

    First the user must had the right that it can open this script and rights that it can snap to directory
    Another problem is if the script is written under windows and is only copy to Solaris, there are a lot of problems with the next line.
    Then you must copy this script and generate to solaris
    under fromdos test.sql
    So you have a script which goes under solaris.

    Regards
    Thomas Schmidt

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