BookmarkSubscribeRSS Feed
pgdelafuente
Calcite | Level 5

Hey there,

I have a list of account names and would like to match them however there are punctuation, spaces & other strings that does not. I already, tried TRIM & Compress and my last road blocked is replacing values like INC. to INCORPORATED.

Sample:

ABC Corp                    = ABC Corporation

A BC Corporation         = ABC Corporation

ABC.Corporation          = ABC Corporation

Hope you can help me on this.

Thanks,

Pablo

3 REPLIES 3
Reeza
Super User

Have you looked at TRANWRD function?

The other option is REGEX

Ksharp
Super User

No other short way. Make a dictionary table and contain all these rules together.

Patrick
Opal | Level 21

What you're after is "standardization". If these are only a few cases like "corp." to "Corporation" then some sort of lookup table approach to translate words could work. If the number of cases is bigger and there could additional ones in the future then software which helps you with standardization would be the optimal way to go. With SAS such standardization "routines" are available via the SAS Data Quality Server ("DataFlux").

hackathon24-white-horiz.png

The 2025 SAS Hackathon Kicks Off on June 11!

Watch the live Hackathon Kickoff to get all the essential information about the SAS Hackathon—including how to join, how to participate, and expert tips for success.

YouTube LinkedIn

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
  • 3 replies
  • 1589 views
  • 0 likes
  • 4 in conversation