Desktop productivity for business analysts and programmers

SAS dataset not displaying variable format

Reply
Occasional Contributor
Posts: 5

SAS dataset not displaying variable format

I Have a sas dataset where all variables have a format tied to them using proc format.  However, the dataset isn't displaying those formats when I have the dataset open, it just shows the raw value.  So for examle 1=male for gender variable.  When I look at the sas dataset I see "1", but if I do a proc print I see "male", so I know the variable actually does have the format because it shows up in proc print.

Anyone know why the format isn't displaying when I look at the raw dataset?  Is there an option in EG that toggles between seeing the raw value vs the formatted value or something?

Thanks,

Dave

Grand Advisor
Posts: 10,223

Re: SAS dataset not displaying variable format

If you have a custom format, which your result of "male" implies, you need to make sure that the library with the format is in the search path.

If you didn't place the format in a permanent library and it was created in WORK, then it was likely erased at the end of your previous session.


Occasional Contributor
Posts: 5

Re: SAS dataset not displaying variable format

It's a format created with "proc format".  It was created in work too, but it was created in my active session, I know the format is tied to the sas dataset because i can see it when doing a "proc print", so I don't think it's an issue with sas not linking them properly.  It just doesn't show up when I'm looking at the sas dataset, the sas dataset shows "1", proc print shows "male"

Contributor
Posts: 32

Re: SAS dataset not displaying variable format

Hi Dave,

I have exact same problem. Did you find a solution to it?

Thanks! lidia

Frequent Contributor
Posts: 108

Re: SAS dataset not displaying variable format

I got similar ploblem and looking around for any solution.

Ask a Question
Discussion stats
  • 4 replies
  • 553 views
  • 0 likes
  • 4 in conversation