BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
jorquec
Quartz | Level 8

 

On SAS Management Console, regarding  how to setting event type dependency between jobs .

Does anyone please  know if  the condition “ Completes Successfully “accept Warnings( yellow msg) when is running jobs or it must be run with any warnings ( warning are not  red errors are just warnings like to delete a table that do not exist will cause a warning msg not an error msg) while running the code.

 

Also does anyone know what is the difference between the condition “ Completes Successfully” and “ Ends with any exit code” ?

 

For example some conditions, such as Ends with exit code and Runs more than, require you to specify additional values (such as the exit code or the number of minutes that the job runs. )

 

Additionally  where I can find a detailed description about all the event types  conditions?

 

Many thanks in advance.

1 ACCEPTED SOLUTION

Accepted Solutions
jklaverstijn
Rhodochrosite | Level 12

I am assuming you have LSF as the scheduler and looking at Flowmanager for the color coding. This is the most common scenario. LSF does not know of a warning condition; it only distinguishes between success (rc=0) and failure (rc>0). This is why many admins decide to reduce a warning completion code (rc=2) to rc=0. Otherwise a warning would potentially stall the progress of a flow. The color yellow in Flowmanager does not indicate a warning but merely the "initializing" or "waiting" state. In that common scenario a warning will  implies success. Otherwise it will be interpreted as an error and the job will show up red.

 

The code to accomplish this is already present in the sasbatch.sh script as comments at the bottom of the file:

# Add this code to capture exit=1 (SAS warning) and make it exit=0
# Comment out exec line above and uncomment the code below to allow the return code to be captured
#"$SAS_COMMAND" -noxcmd -lrecl 32767 "$@" "${USERMODS_OPTIONS[@]}"
#rc=$?
#if [ $rc -eq 1 ]; then
#  rc=0
#fi
#exit $rc

Follow the instruction to turn rc=2 into rc=0.

 

The difference between "completes successfully" and "ends with any exit code" is what it says: a dependent job will either run only when its predecessor end with rc=0 or will always run when the predecessor ends regardless of its return code.

 

The condition "Ends with exit code" allows for user defined return codes (using the SAS abort statement) to control specific paths through the flow.

 

The value for "Runs more than" will trigger a dependent job only when the predecessor runs longer than a specific amount of time. This could help for example when you want to be alerted for unusually long running jobs.

 

SAS and scheduling docs are here.

LSF is extensively documented in this IBM Knowledge Center doc .

Keep in mind that the LSF software that comes with SAS is somewhat limited compared to the full functionality you would buy from IBM.

 

Hope this helps,

- Jan.

View solution in original post

2 REPLIES 2
jklaverstijn
Rhodochrosite | Level 12

I am assuming you have LSF as the scheduler and looking at Flowmanager for the color coding. This is the most common scenario. LSF does not know of a warning condition; it only distinguishes between success (rc=0) and failure (rc>0). This is why many admins decide to reduce a warning completion code (rc=2) to rc=0. Otherwise a warning would potentially stall the progress of a flow. The color yellow in Flowmanager does not indicate a warning but merely the "initializing" or "waiting" state. In that common scenario a warning will  implies success. Otherwise it will be interpreted as an error and the job will show up red.

 

The code to accomplish this is already present in the sasbatch.sh script as comments at the bottom of the file:

# Add this code to capture exit=1 (SAS warning) and make it exit=0
# Comment out exec line above and uncomment the code below to allow the return code to be captured
#"$SAS_COMMAND" -noxcmd -lrecl 32767 "$@" "${USERMODS_OPTIONS[@]}"
#rc=$?
#if [ $rc -eq 1 ]; then
#  rc=0
#fi
#exit $rc

Follow the instruction to turn rc=2 into rc=0.

 

The difference between "completes successfully" and "ends with any exit code" is what it says: a dependent job will either run only when its predecessor end with rc=0 or will always run when the predecessor ends regardless of its return code.

 

The condition "Ends with exit code" allows for user defined return codes (using the SAS abort statement) to control specific paths through the flow.

 

The value for "Runs more than" will trigger a dependent job only when the predecessor runs longer than a specific amount of time. This could help for example when you want to be alerted for unusually long running jobs.

 

SAS and scheduling docs are here.

LSF is extensively documented in this IBM Knowledge Center doc .

Keep in mind that the LSF software that comes with SAS is somewhat limited compared to the full functionality you would buy from IBM.

 

Hope this helps,

- Jan.

jorquec
Quartz | Level 8

Hi,

Thanks for your email , but I am not a sas expert so I didn't understant anything.

I copy an image from DIStudio where my jobs are previous saved to be deployed on SAS Managment Console.

On DI Studio when I manually run a job I can see these messages of Completed Successfully despite a warning , so my doubt is this in Management Console will be consider as Completed Successfully or not ?

Many thanks.

 

sas warning.JPG

suga badge.PNGThe SAS Users Group for Administrators (SUGA) is open to all SAS administrators and architects who install, update, manage or maintain a SAS deployment. 

Join SUGA 

Get Started with SAS Information Catalog in SAS Viya

SAS technical trainer Erin Winters shows you how to explore assets, create new data discovery agents, schedule data discovery agents, and much more.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 2 replies
  • 2003 views
  • 1 like
  • 2 in conversation