capture -jobinfo result in windows batch
Posted: Tue Apr 15, 2008 9:51 am
Hi,
I created a batch file in windows that runs a DS job. I want to check the status of the job and then decide whether a reset is needed. I am having trouble capturing and reusing the result of the status in a variable. Here is my code:
REM GET status info
%DSJOBPATH%\dsjob -jobinfo %PROJECT% %DSJOB%
how do I capture and reuse the result of above in an if statement.
This line DOES NOT WORK:
JOB_STATUS=%DSJOBPATH%\dsjob -jobinfo %PROJECT% %DSJOB%
Thanks,
Juls.
I created a batch file in windows that runs a DS job. I want to check the status of the job and then decide whether a reset is needed. I am having trouble capturing and reusing the result of the status in a variable. Here is my code:
REM GET status info
%DSJOBPATH%\dsjob -jobinfo %PROJECT% %DSJOB%
how do I capture and reuse the result of above in an if statement.
This line DOES NOT WORK:
JOB_STATUS=%DSJOBPATH%\dsjob -jobinfo %PROJECT% %DSJOB%
Thanks,
Juls.