Solved

SQLPlus to run a .sql file

Posted on 2008-10-30
3
1,028 Views
Last Modified: 2013-12-19
Dear experts,

I want to run a .sql which contains some sql code as shown.
However, when I run sqlplus command in windows command prompt.
The sqlplus can successfully login but hold to wait me to input for more?
Mysqlplus command:
"sqlplus username/password@somewhere @c:\oracle\replicate.sql"

I can only quit by pressing Ctrl+C, and I check the result that my script didn't run successfully.

Did my code in .sql missing something?

Many thanks
declare rc binary_integer; 
begin rc := sys.dbms_defer_sys.push(destination=>'DBBK', stop_on_error=>FALSE, delay_seconds=>0, parallelism=>0);
end;

Open in new window

sqlpluserror.JPG
0
Comment
Question by:pomiu
3 Comments
 
LVL 27

Accepted Solution

by:
sujith80 earned 500 total points
ID: 22838679
You have to add  a slash and "exit" at the end of the script.
like
declare rc binary_integer; 
begin rc := sys.dbms_defer_sys.push(destination=>'DBBK', stop_on_error=>FALSE, delay_seconds=>0, parallelism=>0);
end;
/
exit;

Open in new window

0
 
LVL 20

Expert Comment

by:chaitu chaitu
ID: 22838680
0
 
LVL 1

Author Closing Comment

by:pomiu
ID: 31511565
Many thanks.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Note: this article covers simple compression. Oracle introduced in version 11g release 2 a new feature called Advanced Compression which is not covered here. General principle of Oracle compression Oracle compression is a way of reducing the d…
When it comes to protecting Oracle Database servers and systems, there are a ton of myths out there. Here are the most common.
This video shows how to Export data from an Oracle database using the Original Export Utility.  The corresponding Import utility, which works the same way is referenced, but not demonstrated.
This video explains what a user managed backup is and shows how to take one, providing a couple of simple example scripts.

713 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question