Hi all , i need the shell script which would connect to the oracle database xyz...
Connecting To Oracle Database From Unix(script)
Collapse
X
-
Tags: None
-
-Originally posted by chanakyadbaHi all , i need the shell script which would connect to the -oracle database xyz...
Please be clear on what you need, it helps us to be able to answer your question quicker if we do have answers.
Regards,
smashzone -
with sqlplus we can connect , but i need the total syntax from shell prompt and after connecting to sql what steps to be followed to connect to oracle 9i database
Originally posted by smashzone-
Pleas ellaborate on your question? Why would you need a script to connect to a database? Which Oracle database version are you using? Why can't you run sqlplus from the command line?
Please be clear on what you need, it helps us to be able to answer your question quicker if we do have answers.
Regards,
smashzoneComment
-
Definition of a script: a script is an automated sequence of related commands
Therefore, you dont need a script to connect to a database
Step 1
Login to your server (ssh <ip adress>) using program called putty as the oracle user and provide the relevant password
example:
login as: oracle
Sent username "oracle"
oracle@192.168. 103.60's password:
Last login: Wed May 16 09:10:16 2007 from 192.168.103.184
[oracle@slayer ~]$
Step 2
Run the following command:
sqlplus system/password
Step 3
Use sqlplus as you would use it when your connecting using a windows machine.
HINT: Make sure that your logged on as an oracle user, otherwise you'll get an error like this:
[root@slayer ~]# sqlplus
-bash: sqlplus: command not found
Hope this helps, post again if u encounter any problems
Regards,
smashzoneComment
-
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 could you assist, shout if anything is unclear and i will try and re-phaseComment
-
Hi,
I am also in need of some help pertaining to connecting to Oracle from a script. The logic I am trying to accomplish is:
1. log into Oracle.
2. execute a simple select query from the V$SESSION table.
3. have the output piped into a file.
I was planning to have this script set up in crontab to run every 30 mins. Any help will be appreciated. Thanks.Comment
-
Originally posted by aeiou8Hi,
I am also in need of some help pertaining to connecting to Oracle from a script. The logic I am trying to accomplish is:
1. log into Oracle.
2. execute a simple select query from the V$SESSION table.
3. have the output piped into a file.
I was planning to have this script set up in crontab to run every 30 mins. Any help will be appreciated. Thanks.
use "spool" in your sql file and call it to your script.Comment
Comment