BookmarkSubscribeRSS Feed
sandrube
Fluorite | Level 6

Hello friend,

I was trying to incorporate formats into the data and used the following code:

 

libname unos "E:\Data sets\UNOS data\SAS Dataset 202209\Thoracic";
data thoracic_data_1;
set unos.thoracic_data;
options fmtsearch=(unos.formats);
run;

 

formats.sas7bcat and thoracic_data.sas7bdat are in the above folder path.

 

But it didn't work. Can someone guide me please?

 

I appreciate your help!

Rube

2 REPLIES 2
andreas_lds
Jade | Level 19

What do you expect to happen?

The statement "options fmtsearch" extends the catalogs sas uses to find the formats you want applied, but does not assign a format to a variable.

Kurt_Bremser
Super User

What does the log sayß?

Please copy/paste the complete (all code and messages) of your DATA step into a window opened with this button:

Bildschirmfoto 2020-04-07 um 08.32.59.jpg

Also, look at your source data. Run PROC CONTENTS on dataset unos.thoracic_data to see if any special formats coming from unos.formats.catalog are associated with any of the variables in the dataset.

Finally, run PROC CATALOG to see what's in the catalog.

 

SAS catalogs are version- and platform-specific, so your catalog might not work in your environment; and SAS file names must be all lowercase in the filesystem.

SAS Innovate 2025: Register Now

Registration is now open for SAS Innovate 2025 , our biggest and most exciting global event of the year! Join us in Orlando, FL, May 6-9.
Sign up by Dec. 31 to get the 2024 rate of just $495.
Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 2 replies
  • 409 views
  • 0 likes
  • 3 in conversation