BookmarkSubscribeRSS Feed
☑ This topic is solved. Need further help from the community? Please sign in and ask a new question.
ricric
Calcite | Level 5

Usually I would write a shell script in LINUX to execute SAS program.

 

I used to read return code for interpreting the status (success/fail) of the program as below method

ricric_0-1669021438290.png

 

I learnt that in SAS DI, there is a  macro function rcSet(error) that can override the error code.

However, I cannot find a method to overwrite the return code when writing base SAS program.

 

Could anyone advise how to perform same behavior compared to SAS DI?

If really cannot overwrite the error code, is there any way to give out a return code for the shell script to read?

Many thanks.

 

1 ACCEPTED SOLUTION

Accepted Solutions
LinusH
Tourmaline | Level 20

Do I understand you correctly that you want the same behaviour as you have in SAS DI Studio, but implement it in a non-DI Studio program?

You could just copy the rcSet macro definition to your code, and use it like DI Studio generated code does?

Data never sleeps

View solution in original post

1 REPLY 1
LinusH
Tourmaline | Level 20

Do I understand you correctly that you want the same behaviour as you have in SAS DI Studio, but implement it in a non-DI Studio program?

You could just copy the rcSet macro definition to your code, and use it like DI Studio generated code does?

Data never sleeps

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

Mastering the WHERE Clause in PROC SQL

SAS' Charu Shankar shares her PROC SQL expertise by showing you how to master the WHERE clause using real winter weather data.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 1 reply
  • 231 views
  • 0 likes
  • 2 in conversation