wood burning stoves 2.0*
The moose likes Oracle/OAS and the fly likes running sql scripts Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Products » Oracle/OAS
Bookmark "running sql scripts " Watch "running sql scripts " New topic
Author

running sql scripts

Reshma Reddy
Ranch Hand

Joined: Dec 21, 2006
Posts: 197
Hi All,

At the time of running sql scripts it is asking my sourcepath,TNS entry, and password in command prompt I am providing these values(whenever I run script I need to give this values)I am getting these values in my sql script,now I want to provide these values from properties file to run my scripts.Can I get these values from properties files.
Fatih Keles
Ranch Hand

Joined: Sep 01, 2005
Posts: 182
What do you use for executing sql scripts? Is it sqlplus? if so
Reshma Reddy
Ranch Hand

Joined: Dec 21, 2006
Posts: 197
Hi keles,

thanks for your reply,

I don't know exactly how to run these scripts. my database admin is running these scripts at the time of running scripts it is asking path.tns name and password, I want get these fields from properties file I need to get these values in script file it self. now I am taking from command prompt.

regards,
vardhan

Samuel Behrman
Ranch Hand

Joined: Oct 02, 2009
Posts: 49
To run an SQL script, select one of the following options from the Run menu:
All - Runs your SQL script from the beginning to the end. If an error occurs and the Stop on Error option is turned on, the program stops and the statement where the error occurred remains selected.
From Selected - Starts your SQL script from the first statement that is selected or from the current cursor position and continues to the end of the script.
Selected - Runs the statements that are selected.
The results are added to the end of the Messages tab. If the Smart Statement Selection option on the Options menu is not checked, the text that is selected is run as a single SQL statement.


RAQ Report: Web-based Excel-like Java reporting tool.
Reshma Reddy
Ranch Hand

Joined: Dec 21, 2006
Posts: 197
I don't have my scripts in my Database, i need to run the scripts i got(at the time of building application my build file will generate some scripts).

I need to take this scripts and need to run this (Imp: scripts not in database, there in my C drive)


thanks,
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: running sql scripts