Topic: SQL*Plus and PL/SQL >> SQL loader error in unix
|
Disclaimer: The purpose of all dbapool forums including OCP and Other Oracle Certification forums is to help each other with specific issues but not to share dump and copyrighted exam content, materials or intellectual property.
You may review the entire Oracle Certification Program Candidate Agreement online Here.
|
|
|
|
| Title: SQL loader error in unix |
| abhi |
Posted: Jun 02, 2008 06:38:24 AM |
Total Post: 8
Joined: Jan, 2008
|
When i try to run a job in unix, i am getting
sqlload error as,
sqlload : file not found.
Can any one please let me know whats the reason for this..
The PATH & ORACLE_HOME paths names are correct...
thanks |
|
|
Murtuja |
| Posted: Jun 02, 2008 06:53:33 AM | |
|
Total Post: 857
Joined: Jan, 2006
|
Can you post your script here ?
|
|
|
|
|
abhi |
| Posted: Jun 02, 2008 07:30:28 AM | |
|
Total Post: 8
Joined: Jan, 2008
|
here is the script : plz hv a look
TABLE_NAME= tablename
CONTROL_FILE=ctrlname
typeset -i NO_OF_FILES= number
typeset -i I
((I = NO_OF_FILES - 1))
set -A TABLE_NAME_ARRAY table names
set -A LOG_NAME_ARRAY lognames
set -A DATA_FILE_ARRAY datafilesnames
set -A CONTROL_FILE_ARRAY control filesnames
set -A DR_IND_FILE_ARRAY ind filesnames
set -A CR_IND_FILE_ARRAY crind filenames
set -A ARCHIVE_FILE_ARRAY filenames
typeset -i INC=0
while ((INC <= I))
do
TABLE_NAME=${TABLE_NAME_ARRAY[$INC]}; export TABLE_NAME
LOG_NAME=${LOG_NAME_ARRAY[$INC]}; export LOG_NAME
DATA_FILE=${DATA_FILE_ARRAY[$INC]}; export DATA_FILE
CONTROL_FILE=${CONTROL_FILE_ARRAY[$INC]}; export CONTROL_FILE
DR_IND_FILE=${DR_IND_FILE_ARRAY[$INC]}; export DR_IND_FILE
CR_IND_FILE=${CR_IND_FILE_ARRAY[$INC]}; export CR_IND_FILE
TAR_FILE=${ARCHIVE_FILE_ARRAY[$INC]}; export TAR_FILE
date > ${LOG_HOME}/${LOG_NAME}.out
sqlplus -s $USER_ID/$USER_PWD @${SCRIPT_HOME}/truncate_table.sql $TABLE_NAME $USER_ID >> ${LOG_HOME}/${LOG_NAME}.out
mfi.sh $DATA_FILE ${LOG_NAME}.log ${LOG_NAME}.out $CONTROL_FILE PRELOAD $TABLE_NAME 0 > /dev/null
# Run the load script
sqlload $USER_ID/$USER_PWD,\
CONTROL=${SCRIPT_HOME}/${CONTROL_FILE},\
DATA=${DATA_DIR}/${DATA_FILE},ROWS=4000,\
BINDSIZE=500000,\
BAD=/tmp/${LOG_NAME}.bad,\
LOG=${LOG_HOME}/${LOG_NAME}.log >> /dev/null
print Analyzing table ${TABLE_NAME}... >> ${LOG_HOME}/${LOG_NAME}.out
sqlplus -s $USER_ID/$USER_PWD @${SCRIPT_HOME}/analyze_table.sql $TABLE_NAME >> ${LOG_HOME}/${LOG_NAME}.out
mfi.sh $DATA_FILE ${LOG_NAME}.log ${LOG_NAME}.out $CONTROL_FILE POSTLOAD $TABLE_NAME 0 > /dev/null
touch ${LOG_HOME_1}/${USER_ID}.${TABLE_NAME}.ready
((INC += 1))
done
|
|
|
|
|
Gitesh |
| Posted: Jun 03, 2008 07:13:49 AM | |
|
Total Post: 322
Joined: May, 2005
|
Which is the path of $SCRIPT_HOME and $LOG_HOME? After giving proper path. Do you have permission to create file in same location?
|
|
|
|
|
| Time Zone: EDT |
Send this thread to your friend |
|
|
|
|
Forum Rules & Description
Who Can Read The Forum? Any registered user or guest
Who Can Post New Topics? Any registered user
Who Can Post Replies? Any registered user
|
| |
Get FREE Magazines
|
Top 10 Forum User
|
| Murtuja Khokhar | 857 |
| Mohammed Taj | 746 |
| positive fanatic | 483 |
| Jayanta Sur | 479 |
| Vigyan Kaushik | 387 |
| Vinoth Kumar | 379 |
| Gopu Gopi | 350 |
| Gitesh Trivedi | 322 |
| neeraj sharma | 258 |
| Ramesh Jois | 246 |
|
|