Using Permanently Assigned Labels and Formats

When you use a LABEL or FORMAT statement within a PROC step, the label or format applies only to the output from that step.
However, in PROC steps, you can also use permanently assigned labels or formats. Permanent labels and formats can be assigned in the DATA step. These labels and formats are saved with the data set, and they can be reused by procedures that reference the data set.
For example, the DATA step below creates Flights.March and defines a format and label for the variable Date. Because the LABEL and FORMAT statements are inside the DATA step, they are written to the Flights.March data set and are available to the subsequent PRINT procedure.
data sasuser.paris; set sasuser.laguardia; ...

Get SAS Certification Prep Guide, 4th Edition 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.