Discover More Tips and Techniques on This Blog

How to get the details of formats from the format libraries:

If you are like me wanted to get the details of formats stored in the format library, here are two easy ways ….Proc catalog or Proc format

Proc Catalog: Proc catalog will give us the details about name and type (numeric or character) of formats

Syntax:
proc catalog catalog = frmtdir.formats;
contents;
run;

*FORMATS, is the name of the folder where all permanent formats are stored inside the library FRMTDIR.

*If you want to get the details of temporary formats use WORK in place of frmtdir.formats;

Proc Format:

Use either SELECT or EXCLUDE statements to choose the formats for which you want to get the details.

Syntax:

proc format library = frmtdir.formats;
select locfmt;
run;

This code will provide the details of LOCFMT in the FRMTDIR library.


Below code gives complte information about what's stored in your format catalogs.

libname frmtdir 'c:\saswork';


proc format library=frmtdir.formats cntlout = formats;
run;

Look at the output dataset 'formats' to get the details of the formats.

('DiggThis’)

Disclosure:

In the spirit of transparency and innovation, I want to share that some of the content on this blog is generated with the assistance of ChatGPT, an AI language model developed by OpenAI. While I use this tool to help brainstorm ideas and draft content, every post is carefully reviewed, edited, and personalized by me to ensure it aligns with my voice, values, and the needs of my readers. My goal is to provide you with accurate, valuable, and engaging content, and I believe that using AI as a creative aid helps achieve that. If you have any questions or feedback about this approach, feel free to reach out. Your trust and satisfaction are my top priorities.