Help using Base SAS procedures

Proc Contents question: SAS library directory

Reply
Frequent Contributor
Posts: 100

Proc Contents question: SAS library directory

Hi there:
I read that proc contents can be used to print the directory of a SAS library. But when I practiced (using the ._all_) my output list only included SAS datasets in that libref folder. My .sas files (i.e. the sas program code files) did not show up as I expected. Then I noticed that they were not in my library windows either. Maybe .sas files are not really considered SAS files?

Here is my code & log info. Did I miss something? Thank you!

25 proc contents data=prog2._all_;
26 run;

NOTE: Writing HTML Body file: sashtml8.htm
WARNING: No matching members in directory
Super Contributor
Super Contributor
Posts: 3,174

Re: Proc Contents question: SAS library directory

Files with the *.sas file-extension are SAS programs, not database files. As you encountered, PROC CONTENTS is used to print SAS database inventory / attribute information.

Scott Barry
SBBWorks, Inc.
Frequent Contributor
Posts: 100

Re: Proc Contents question: SAS library directory

Thank you. Wish the beginner study materials / documentation can be more concise or I guess most people are not puzzled by it.
Ask a Question
Discussion stats
  • 2 replies
  • 140 views
  • 0 likes
  • 2 in conversation