BookmarkSubscribeRSS Feed
CatherineLim
Calcite | Level 5

Hi, in one of the numeric column of my dataset, I have 3 digits and 4 digits number.
I want to remove the last digit if the number have 4 digit, for example:

No Score

1 789

2 673

3 6470

4 783

5 7280 

6 785

 

I want the 6470 to become 647 and 7280 to become 728, how should I do that with SAS programming?

2 REPLIES 2

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
  • 2 replies
  • 1132 views
  • 1 like
  • 3 in conversation