A forum for discussing DataStage<sup>®</sup> basics. If you're not sure where your question goes, start here.
Moderators: chulett, rschirm, roy
-
abc123
- Premium Member
- Posts: 605
- Joined: Fri Aug 25, 2006 8:24 am
Post
by abc123 »
I have an execute command stage in a sequence job. I am running the following command in the execute command stage:
sqlplus Userid/Pwd@SrcName < /fullpath/MySqScript.sql
When I try to execute the sequence job, I get the following error:
seqJob..JobControl (@ExecCmd1): Executed:
sqlplus Userid/Pwd@SrcName < /fullpath/MySqScript.sql;
Reply=1
Output from command ====>
sh: /fullpath/MySqScript.sql: Permission denied
I tried doing the other way as well:
Command: sqlplus
Parameters: Userid/Pwd@SrcName < /fullpath/MySqScript.sql
Same result. The file, MySqScript.sql, has full chmod 777 permissions. Any ideas?
[Note: Title changed since this technically isn't a "SQL Plus" error - Andy]
-
Mike
- Premium Member
- Posts: 1021
- Joined: Sun Mar 03, 2002 6:01 pm
- Location: Tampa, FL
Post
by Mike »
Also check the permissions at every level of /fullpath.
Mike
-
abc123
- Premium Member
- Posts: 605
- Joined: Fri Aug 25, 2006 8:24 am
Post
by abc123 »
I did. They all have:
drwxr-xr-x
Also, when I execute:
sqlplus Userid/Pwd@SrcName < /fullpath/MySqScript.sql
from within /fullpath/, it works fine.
-
priyadarshikunal
- Premium Member
- Posts: 1735
- Joined: Thu Mar 01, 2007 5:44 am
- Location: Troy, MI
Post
by priyadarshikunal »
with limited information you have provided, i think if fullPath is a parameter, you are passing that incorrectly.
Priyadarshi Kunal
Genius may have its limitations, but stupidity is not thus handicapped.
-
chulett
- Charter Member
- Posts: 43085
- Joined: Tue Nov 12, 2002 4:34 pm
- Location: Denver, CO
Post
by chulett »
From a permissions standpoint when you say "when I execute" that's only a valid test if you are logged in as the same user that executes the job.
-craig
"You can never have too many knives" -- Logan Nine Fingers
-
PaulVL
- Premium Member
- Posts: 1315
- Joined: Fri Dec 17, 2010 4:36 pm
Post
by PaulVL »
Long shot but... Go look in your project path to see if some dastardly person created a file called sqlplus.
Then type in "which sqlplus" to see where you are pulling it from.
-
UCDI
- Premium Member
- Posts: 383
- Joined: Mon Mar 21, 2016 2:00 pm
Post
by UCDI »
Try making a dummy script that does nothing except echo your username and password to the screen to see if those are coming to the script as expected?
As a side effect, if a script that does nothing except echo fails, you have a problem with permissions to run scripts?