BookmarkSubscribeRSS Feed
Lilik
Fluorite | Level 6

Good day dear All,

I have some difficulties in finding continent names in sashelp.demographics. The requirement is to  "Get the CONTNAME variable with the following values, without using any formats". In dataset there are continent codes. Could you help me with this?

Thanks in advance.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

1 REPLY 1
ballardw
Super User

If you are supposed to be looking for specific values then you should share the specific values you are using.

 

 "Get the CONTNAME variable with the following values, without using any formats". My first thought would be to use an INFORMAT, which is not a Format, but I suspect that you are supposed to build a table with the actual values of the CONTNAME variable and the associated values you want to use as part of join to get the desired values. The easiest way to do that would likely be a data step reading the paired values.

sas-innovate-2026-white.png



April 27 – 30 | Gaylord Texan | Grapevine, Texas

Registration is open

Walk in ready to learn. Walk out ready to deliver. This is the data and AI conference you can't afford to miss.
Register now and lock in 2025 pricing—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
  • 1 reply
  • 1362 views
  • 0 likes
  • 2 in conversation