How to Save a Permanent SAS Dataset
Save a Permanent SAS Dataset
In order to save a temporary dataset as a permanent dataset in a SAS library, you will need to use the DATA and SET statements. The sample code below, which comes from the “PAXMSTR” program, shows how to save the temporary dataset, PXMSTR, as a permanent SAS dataset. This permanent dataset will be saved in the SAS library, NHANES, which was created in the Download Data Files Module (please note that if you set up your file structure differently than what was presented in that module, you will need to adjust your SAS program accordingly).
Check that the Dataset was Saved to a SAS-Accessible Library
To check that your dataset was saved to the NHANES library:
- Open the SAS Explorer.
- When the Explorer opens, open the Library icon.
Double-click on NHANES library. The contents of NH library will be displayed in the right-hand window labeled "Contents" and should include your new permanent dataset, PAXMSTR.