Ma*********@eds.com (Mark D Powell) wrote in message news:<26**************************@posting.google. com>...
to*********@yahoo.com (tommy) wrote in message news:<4f**************************@posting.google. com>... I'm running sqlplus from a DOS command line and inducing an error by
purposly giving it the wrong script (hence, it cannot find the script
file.) What it is doing is exiting to the SQL> prompt as show below.
What I NEED it to do is exit to the DOS prompt.
c:\>sqlplus someuser/mypass@mydb NonExistantCommandFile.sql
SQL>
Does someone know how this can be done or have a commandline switch
reference that might have the answer?
Look in the sqlplus manual for logon.sql (or perhaps login) scripts.
You can set parameters in this file that will take affect when the
session is started. You could set the sqlwhenever clause to exit on
failure. At least this is what I would try. I am not on a computer
with Oracle on it so I cannot test my suggestion but it should be
pretty easy to test.
HTH -- Mark D Powell --
You should place the SQL in your "BIN" directory
and all you should need is
c:\@NonExistantCommandFile
also try saving something from the dos prompt and see where
it gets saved and then place the sql code in that directory
if its not the BIN directory
george