Hi
Is any one help me how to call DataStage job using PERL in unix server.
Will appreciate if any one can provide the code for calling datastage job.
Thanks in advance
Calling DataStage job using PERL in unix server
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
There is a command line interface called dsjob that you invoke from your Perl script.
Read about dsjob by searching the forum, or by reading either the Server Job Developer's Guide or the Parallel Job Developer's Guide. It's also mentioned in the DataStage Operator's Guide.
Read about dsjob by searching the forum, or by reading either the Server Job Developer's Guide or the Parallel Job Developer's Guide. It's also mentioned in the DataStage Operator's Guide.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
You invoke an external command using backticks as
But I'm curious to know why you want to run dsjob using perl.
Code: Select all
`dsjob -server ....`
Jim Paradies
Now I'm totally confused. If you're calling DataStage from a unix script then all you have to do is call it like any other unix command.I will call the unix script using the PERL job and internally unix script will call the DataStage job.
i.e
dsjob -server ...
You then call the unix script from within Perl using the backtick syntax. As for whether you need any special libraries, the answer is no.
But I'm still trying to understand what advantage you hope to gain by running everything under Perl. Do you use Perl as some sort of intelligent controller for all you jobs?
Jim Paradies
Where do i need to place my Unix shell script .Is it under Project folder ?
Actually i am getting folowing while using -
${DSBINDIR}/dsjob -run -mode NORMAL
-param '$prmfilepath'='/data/dw/af2/rawdata/Strategyware060112.txt' -warn $WARN_LIMIT -jobstatus $PROJ $JOB
Error is - StrategyWareLoad.sh[30]: /dsjob: not found
Please help me in understanding why i am getting this error.
Thanks in advance
Actually i am getting folowing while using -
${DSBINDIR}/dsjob -run -mode NORMAL
-param '$prmfilepath'='/data/dw/af2/rawdata/Strategyware060112.txt' -warn $WARN_LIMIT -jobstatus $PROJ $JOB
Error is - StrategyWareLoad.sh[30]: /dsjob: not found
Please help me in understanding why i am getting this error.
Thanks in advance
rv