BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
gandikk
Obsidian | Level 7

Hi,

 

I need to check few symbols while applying PROPCASE on my data. Underscore is part of my symbols. When I included underscore in my code as O_NAM1 = PROPCASE(I_NAM1, " .<(+|&!$*);¬-/,%_`"), I got a warning "Apparent invocation of macro _ not resolved". How can I include underscore in my code? When I kept the underscore in single quotes, pgm considered single quote as a valid symbol and checked the data for single quote. I don't want to search data for single quote.

 

Thanks in advance!!

SAS@EMMAUS
1 ACCEPTED SOLUTION

Accepted Solutions
Astounding
PROC Star

%_ would be a valid name for a macro.  To fix the problem, just switch the order within your string:  _% instead of %_

View solution in original post

4 REPLIES 4
Astounding
PROC Star

%_ would be a valid name for a macro.  To fix the problem, just switch the order within your string:  _% instead of %_

gandikk
Obsidian | Level 7

Thank you!!

 

SAS@EMMAUS
ballardw
Super User

Or use single quotes to delimit the string.

gandikk
Obsidian | Level 7
Thank you!!
SAS@EMMAUS

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 16. Read more here about why you should contribute and what is in it for you!

Submit your idea!

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.

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