Unix Return Code
Posted: Thu Apr 24, 2008 12:48 pm
Hi-
I tried searching for an answer here for this without luck. I'm still new to DataStage so please bear with me.
I have a DataStage Sequence I'm trying to get to work. The first stage in the sequence is an Execute Command stage (named Execute_Command_0). This stage executes a shell script on the UNIX server, which will set a return code to eiher zero or one. The Execute Command stage has two triggers, the first has Expression Type "OK - Conditional", the other has "Custom - Conditional". The problem is with the "Custom - Conditional". I have the expression in the trigger for this as follows:
Execute_Command_0.$ReturnValue = '1'
When I execute the job it aborts with the error messages below. But since I'm explicitly testing for this return code I'm not sure why DataStage is treating this as an Unhandled Failure. I also tried changing the Expression Type for the trigger to ReturnCode - Conditional, and setting the Expression to 1, but that also didn't work. I also tried changing the Expression to '1' and "1" which also didn't work.
In Director I see the following Warnings:
WARNING
checkWeekTest..JobControl (@Execute_Command_0): Command /sbin/sh /home/dsadm/scripts/checkWeek.sh did not finish OK, reply = '1'
WARNING
checkWeekTest..JobControl (@Execute_Command_0): Controller problem: Unhandled failure (1) encountered executing command /sbin/sh /home/dsadm/scripts/checkWeek.sh
INFO
checkWeekTest..JobControl (@Coordinator): Summary of sequence run
14:27:14: Sequence started (checkpointing on)
14:27:14: Execute_Command_0 (COMMAND /sbin/sh /home/dsadm/scripts/checkWeek.sh) started
14:27:15: Execute_Command_0 finished, reply=1
14:27:15: Exception raised: @Execute_Command_0, Unhandled failure (1) encountered executing command /sbin/sh /home/dsadm/scripts/checkWeek.sh
14:27:15: Sequence failed (restartable)
FATAL
checkWeekTest..JobControl (fatal error from @Coordinator): Sequence job (restartable) will abort due to previous unrecoverable errors
Any help would be greatly appreciated!!
I tried searching for an answer here for this without luck. I'm still new to DataStage so please bear with me.
I have a DataStage Sequence I'm trying to get to work. The first stage in the sequence is an Execute Command stage (named Execute_Command_0). This stage executes a shell script on the UNIX server, which will set a return code to eiher zero or one. The Execute Command stage has two triggers, the first has Expression Type "OK - Conditional", the other has "Custom - Conditional". The problem is with the "Custom - Conditional". I have the expression in the trigger for this as follows:
Execute_Command_0.$ReturnValue = '1'
When I execute the job it aborts with the error messages below. But since I'm explicitly testing for this return code I'm not sure why DataStage is treating this as an Unhandled Failure. I also tried changing the Expression Type for the trigger to ReturnCode - Conditional, and setting the Expression to 1, but that also didn't work. I also tried changing the Expression to '1' and "1" which also didn't work.
In Director I see the following Warnings:
WARNING
checkWeekTest..JobControl (@Execute_Command_0): Command /sbin/sh /home/dsadm/scripts/checkWeek.sh did not finish OK, reply = '1'
WARNING
checkWeekTest..JobControl (@Execute_Command_0): Controller problem: Unhandled failure (1) encountered executing command /sbin/sh /home/dsadm/scripts/checkWeek.sh
INFO
checkWeekTest..JobControl (@Coordinator): Summary of sequence run
14:27:14: Sequence started (checkpointing on)
14:27:14: Execute_Command_0 (COMMAND /sbin/sh /home/dsadm/scripts/checkWeek.sh) started
14:27:15: Execute_Command_0 finished, reply=1
14:27:15: Exception raised: @Execute_Command_0, Unhandled failure (1) encountered executing command /sbin/sh /home/dsadm/scripts/checkWeek.sh
14:27:15: Sequence failed (restartable)
FATAL
checkWeekTest..JobControl (fatal error from @Coordinator): Sequence job (restartable) will abort due to previous unrecoverable errors
Any help would be greatly appreciated!!