Page 1 of 1

HOw to start the datastage job from win bat file or DOS mode

Posted: Thu May 03, 2007 2:46 am
by ICE
HI All,

May I know how to start the datastage jobs using window bat file or MS DOS prompt???
I believe that we can do that like unix shell script.Am I right?
:roll:


Thanks,

To Start DS Job from a batch file of windows

Posted: Thu May 03, 2007 3:01 am
by suresh.narasimha
Hi,

I gues this should help you when you put this in a batch.

C:\Ascential\DataStage\Engine\bin\dsjob -server <server_name> -user <User_Name> -password <somepwd> -run <Project_Name> <Job_Name>

Regards,
Suresh N

Posted: Thu May 03, 2007 7:18 am
by chulett
Yes, the dsjob command. Read the Command Line Interface section of the Server Job Developer's Guide for details.

An example in a ".bat" file

Posted: Thu May 03, 2007 10:57 am
by MikeGoldrick
:runjob
C:\Ascential\DataStage\Engine\Bin\dsjob -file %fname% %rserver% -run -jobstatus %project% %job%
::
if not errorlevel 2 goto end
C:\Ascential\DataStage\Engine\Bin\dsjob -file %fname% %rserver% -run -mode RESET %project% %job%
C:\Ascential\DataStage\Engine\Bin\dsjob -file %fname% %rserver% -logsum -type INFO -max 50 %project% %job%
::

where
%fname contains the userid/pwd in a file
%rserver is the server name
%project is the ds project name
%job is the job you are running

The 1st dsjob runs the job
The 2nd Resets the job if it abends
The 3rd dumps parts of the log file

Hope that helps.

Posted: Thu May 03, 2007 7:36 pm
by ICE
Dear All,

Thank u so much.Thanks a lot.
I will try and let u know then.
I really appreciate you all advise.

Thanks a lot.. :)

Posted: Thu May 03, 2007 8:40 pm
by ICE
Dear All,

I solve it.
I can start the DS job from Dos mode. Thank you all.Especially thanks a lot and thank you so much Suresh and Mike. I really appreciate you 2 advise.
Thanks........thanks a lot........... :D


Thanks in advance.

Posted: Thu May 03, 2007 8:43 pm
by U
ICE wrote:Dear All,

Thank u so much.Thanks a lot.
I will try and let u know then.
I really appreciate you all advise.

Thanks a lot.. :)
Please don't let me delay your search for someone who cares.

U is my name.
"YOU" is a personal pronoun.
Please get it right.

Posted: Sat Jun 02, 2007 8:56 pm
by ICE
Dear U,

Could u pls chk ur private msg?

Thanks,

U wrote:
ICE wrote:Dear All,

Thank u so much.Thanks a lot.
I will try and let u know then.
I really appreciate you all advise.

Thanks a lot.. :)
Please don't let me delay your search for someone who cares.

U is my name.
"YOU" is a personal pronoun.
Please get it right.