BookmarkSubscribeRSS Feed
jmhill
Calcite | Level 5

I have a data set with 2 columns (NAME and ENTRIES).

I an trying to get the name only to display as many times as there are entries. I thought using a DO UNTIL or WHILE statement would be the most efficient, but I am not sure.

Sample data and results set expected attached.

 

1 REPLY 1
PGStats
Opal | Level 21

Simple iterative DO will suffice

 

Do i = 1 to entries;

output;

end;

keep name;

PG

hackathon24-white-horiz.png

2025 SAS Hackathon: There is still time!

Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!

Register Now

Creating Custom Steps in SAS Studio

Check out this tutorial series to learn how to build your own steps in SAS Studio.

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
  • 1012 views
  • 0 likes
  • 2 in conversation