BookmarkSubscribeRSS Feed
mdavidson
Quartz | Level 8
I'm trying to rank query results, what I currently have is a count by individual name. What I'm trying to accomplish is a "rank" field that looks like the following below. The "RANK" function in SAS EG doesn't seem to provide me with the results I'm looking for. Can someone point me in the right direction?

Name Count Rank
Mike 32 1
Bill 29 2
Jim 24 3
Cindy 24 3
Bob 19 5
Dave 17 6 Message was edited by: mdavidson
1 REPLY 1
Doc_Duke
Rhodochrosite | Level 12
I think that what you want to use is the RANK Task under the Data Tab. If it returns mid-ranks (3.5's where you have 3's), you can use the FLOOR function in the query to remove the decimal part.

Ready to join fellow brilliant minds for the SAS Hackathon?

Build your skills. Make connections. Enjoy creative freedom. Maybe change the world. Registration is now open through August 30th. Visit the SAS Hackathon homepage.

Register today!
SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 1 reply
  • 1024 views
  • 0 likes
  • 2 in conversation