Need help with shell script which calls Datastage Job

A forum for discussing DataStage<sup>®</sup> basics. If you're not sure where your question goes, start here.

Moderators: chulett, rschirm, roy

Post Reply
mac4rfree85
Participant
Posts: 126
Joined: Thu Jul 01, 2010 11:39 pm

Need help with shell script which calls Datastage Job

Post by mac4rfree85 »

Hi Guys,

I have shell script which is calling Datastage job and is running perfectly.
The problem is the parameters needed are in a Oracle table which i need to fetch.
I am able to fetch them if i write in a separate script,but when i include the same code in the script which is calling Datastage (sourcing dsenv file), the sql is failing with the below errror.

Code: Select all

Error 19 initializing SQL*Plus
Invalid NLS character set for this OS environment
My guess is dsenv is changing some of the required params for Oracle. Has anybody included a SQL command in a Datastage calling Script.

Please guide me as what i am doing wrong.

Cheers!!!!
Mac4rfree
datisaq
Participant
Posts: 154
Joined: Wed May 14, 2008 4:34 am

Post by datisaq »

Make sure you have ORACLE_HOME and ORACLE_SID variables properly set for the environment.

then use sqlplus -s username/pwd comnd for logging
after that u can just type SQL cmnds directly.

e.g:-

sqlplus -S $user/$pass <<EOF
SELECT * FROM tableName;
exit;
EOF
IBM Certified - Information Server 8.1
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

If you still have an issue, suggest you post the relevant section of your script.
-craig

"You can never have too many knives" -- Logan Nine Fingers
Post Reply