Chapter 5: RUN_MACRO and RUN_SASFILE

The FCMP procedure supports several built-in SAS functions not otherwise available in Base SAS. RUN_MACRO and RUN_SASFILE are two of the most powerful functions, with the former calling a SAS macro and the latter calling a SAS program file from inside a user-defined function or subroutine. RUN_MACRO and RUN_SASFILE enable SAS macros, which can enclose Base SAS statements, DATA steps, and procedures, to be executed inside of functions. This versatility facilitates some pretty unimaginable software design, not otherwise possible in the SAS language.

In a general, programming-language-agnostic sense, functions communicate with a calling module by returning a value—the return value—as discussed throughout Chapter ...

Get PROC FCMP User-Defined Functions now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.