kristof
kristof

Reputation: 53824

SAS : Maximum number of data sets per library

What is the maximum number of data sets that can be created in SAS library? Is there a difference in limit (if any) for permanent and temporary libraries like work library?

I can find e.g. information that up to SAS 9.1 the maximum number of variables per data set was 32,767 and that from SAS 9.1 it is only limited by system resources, but I cannot find any info about the number of data sets per library

Upvotes: 2

Views: 1851

Answers (1)

user667489
user667489

Reputation: 9569

I suspect that any such limit is more likely to stem from the underlying file system than from SAS itself, as described in this answer:

How many files can I put in a directory?

On a somewhat pedantic note, it is perhaps worth pointing out that a sas dataset can consist of multiple files - so as well as a primary .sas7bdat file you might have numerous connected files, e.g. for indexes, audit trails, and generation data sets (up to 1000!). If you have lot of these then you will obviously hit the file system ceiling somewhat sooner. Depending on the file system, you might find that you get some sort of performance degradation when listing all the files in the folder. However, for anything more recent than FAT32 I doubt you'd ever hit any practical limit based on the number of files (as opposed to their total size).

Also, a standard cautionary point: it isn't clear what you're doing with SAS that would need so many files; quite often in such cases it is much neater and more efficient to put everything in one big dataset and take advantage of by-group processing.

Upvotes: 1

Related Questions