SAS Institute. The Power to Know

SAS(R) 9.2 Macro Language: Reference

Previous Page | Next Page

What's New

What's New in the SAS 9.2 Macro Language Facility


Overview

The Macro Language Facility has the following enhancements:

  • new automatic macro variables that enable you to reduce the amount of text that is needed to perform common tasks

  • new macro system options that enable you to define and redefine macros and to better control their execution

  • new %MACRO statement options that enable you to create secure macros and to integrate macros with other parts of your SAS programs


New Automatic Macro Variables

  • The &SYSENCODING automatic macro variable contains the name of the current session encoding.

  • The &SYSERRORTEXT automatic macro variable contains the text of the last error message formatted for display on the SAS log.

  • The &SYSHOSTNAME automatic macro variable contains the host name of a computer.

  • The &SYSLOGAPPLNAME automatic macro variable contains the value of the LOGAPPLNAME system option. This automatic macro variable is for SAS 9.2 Phase 2 and later.

  • The &SYSTCPIPHOSTNAME automatic macro variable contains the host names of the local and remote computers when multiple TCP/IP stacks are supported.

  • The &SYSWARNINGTEXT automatic macro variable contains the text of the last warning message formatted for display on the SAS log.


New SAS Macro System Options

  • The MCOMPILE system option allows new definitions of macros.

  • The MEXECNOTE system option displays the macro execution information in the SAS log at macro invocation.

  • The MEXECSIZE system option specifies the maximum macro size that can be executed in memory.

  • The MINOPERATOR system option specifies that the macro processor recognizes and evaluates the mnemonic IN and the special character # as logical operators when evaluating arithmetic or logical expressions during the execution of the macro.

  • The MREPLACE system option enables existing macros to be redefined.


New Options for the %MACRO Statement

  • The MINDELIMITER= option specifies a value that overrides the MINDELIMITER= global option during a macro session.

  • The SECURE option enables you to write secure macros that protect intellectual property contained in stored compiled macros.

  • The MINOPERATOR option specifies that the macro processor recognizes and evaluates the mnemonic IN and the special character # as logical operators when evaluating arithmetic or logical expressions during the execution of the macro.

Previous Page | Next Page | Top of Page