473,378 Members | 1,309 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,378 software developers and data experts.

Connecting To Oracle Database From Unix(script)

Hi

I would like to create a unix script to connect to an ORACLE database using a oracle package. Also this script should provide functionality to call an oracle procedure that contains a parameter value that is passed to it. The parameter value passed to the procedure should be "editable" i.e user should be able to change it.

Please specify if any more information is needed

what I have done is the following
example script name -> Unixscript_run.sql
-- start sqlplus session
SQLPLUS
-- enter username and password when promted to login
-- define the value of the parameter passed to the procedure

DEFINE myVariable = 'xyz';

-- call to the program to connect to db

EXECUTE packageName.Procedurename(myVariable);

-- Display any errors encountered in the package and procedure
SHOW ERRORS packageName;]
SHOW ERRORS PROCEDUREname(myVariable);
-- Disconnect from sqlplus session once complete
DISCONNECT;


Thanks
Aug 6 '07 #1
1 2537
RedSon
5,000 Expert 4TB
Moved from Misc questions. Maybe these guys can help you.
Aug 6 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Alan Wang | last post by:
Hi all: I am just wondering if it's possible to call Unix script from asp.net application. Thanks in advanced Alan
1
by: Alan Wang | last post by:
Hi all: I am just wondering if it's possible to call Unix script from VB.Net application. Thanks in advanced Alan
2
by: obodner | last post by:
hi all, can any one help with writting a unix script that knows to pull out from a file a string and retype it to a new file. the string could appear in the file with a different value but its...
0
by: oakwoodman | last post by:
I have a UNIX script that invokes a DB2 UDB .sql script. I need to pass parameters to the .sql script from the .sh. How does one reference the parameters in the .sql script? The .sql script is not...
1
by: nadarajanseetharaman | last post by:
Hi, Please let me know how the load utility of DB2 can be called using the unix script. Regards, Nadarajan.
0
by: miguelpastor | last post by:
Hello, I need to remotely start a unix script (in a unix box) from a windows 2003 server. How can I do that? Thank you for your time, Pastor
0
by: iitt2007 | last post by:
Hi I am newbie. I need to translate the following Oracle script to SQL Server 2005 script. I will appreciate your help and feedback. Thanks a lot in advance. ...
0
by: Edwin.Madari | last post by:
here is a working code snippet to read from MySQL db. python tutorial has examples of reading from files. put them together to do your task. ===================================================...
0
by: suganthibytes | last post by:
hi, please tell me how to call a unix script from C#
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.