As the first step in the decommissioning of the site has been converted to read-only mode.

Here are some tips for How to share your SAS knowledge with your professional network.

Tips:Using IFC to Conditionally Execute Global Statements

From sasCommunity
Jump to: navigation, search

The IFC function can be used to conditionally execute global statements, including the %PUT, %LET, and %INCLUDE statements.

Both IFN and IFC can be used with the macro language. IFC returns a character value, while IFN returns a numeric. When building code it is generally more useful to have a character result.

%let name=Fred;
%put %sysfunc(ifn(&name=Charlie,1,2,3));

Submitted by Art Carpenter. Contact me at my Discussion Page.

....see also more