CORE
mp_dirlist.sas File Reference

Returns all files and subdirectories within a specified parent. More...

Go to the source code of this file.

Detailed Description

Returns all files and subdirectories within a specified parent.

Not OS specific (uses dopen / dread). It does not appear to be possible to reliably identify unix directories, and so a recursive option is not available. usage:

%mp_dirlist(path=/some/location,outds=myTable);
Parameters
path=for which to return contents
outds=the output dataset to create
Returns
outds contains the following variables:
  • file_or_folder (file / folder)
  • filepath (path/to/file.name)
  • filename (just the file name)
  • ext (.extension)
  • msg (system message if any issues)
Version
9.2
Author
Macro People Ltd

Definition in file mp_dirlist.sas.