By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
464,482 Members | 1,158 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 464,482 IT Pros & Developers. It's quick & easy.

sqlloader shell script

P: 75
Hi am calling sqlloader inlow shell script

#!/bin/sh
sqlldr scott/tiger control=ulcase1.ctl log=ulcase1.log
retcode=`echo $?`
case "$retcode" in
0) echo "SQL*Loader execution successful" ;;
1) echo "SQL*Loader execution exited with EX_FAIL, see logfile" ;;
2) echo "SQL*Loader exectuion exited with EX_WARN, see logfile" ;;
3) echo "SQL*Loader execution encountered a fatal error" ;;
*) echo "unknown return code";;
esac

#!/bin/ksh

while read table_name
do
echo "

I have set database name as scott/tiger .

I have following queries

1) what need to be done if i need to call that shell script in another database .
Means everytime its not posible to change the database name ..

is there any automatic process for it

thanks
Jun 18 '08 #1
Share this Question
Share on Google+
1 Reply

gpraghuram
Expert 100+
P: 1,275
If you want to change the database name on the fly then declare a variable and use it in the command.
The variable will be initialized either from command prompt or from a file

Hope i am clear

Raghu
Jun 19 '08 #2

Post your reply

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