CONTENTS Procedure

Overview: CONTENTS Procedure

The CONTENTS procedure shows the contents of a SAS data set and prints the directory of the SAS library.
Generally, the CONTENTS procedure functions the same as the CONTENTS statement in the DATASETS procedure. The differences between the CONTENTS procedure and the CONTENTS statement in PROC DATASETS are as follows:
  • The default for libref in the DATA= option in PROC CONTENTS is WORK. For the CONTENTS statement, the default is the libref of the procedure input library.
  • PROC CONTENTS can read sequential files. The CONTENTS statement cannot.