BookmarkSubscribeRSS Feed
deleted_user
Not applicable
When using the compress function with the P modifier, which removes all punctuation from a string, what is the definition of punctuation?
2 REPLIES 2
polingjw
Quartz | Level 8
If you look at the documentation on the ANYPUCT function, the following characters are considered punctuation in the ASCII character set:

! “ # $ % & ‘ ( ) * + , - . / : ; = ? @ [ \ ] ^ _ ` { | } ~

In addition, the less than and greater than symbols are also considered punctuation. (I can’t remember how to properly post these characters in this forum.) I would imagine that the same character set would be considered punctuation when using the compress function with the P modifier.
deleted_user
Not applicable
Thank you.

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

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
  • 2626 views
  • 1 like
  • 2 in conversation