03-17-2015 09:42 AM
In the example below I list some products with descriptions containing superscripted ordinals. I want to find any product description that has a raised st, nd, rd or th. I do not need to find products that don't have the raised lettering, such as in the examples 1st, 2nd, 3rd or 4th.
03-17-2015 10:17 AM
I don't think so. I believe that the superscripted letters are just regular letters with a different font, and I can't see anything in REGEX documentation that deals with fonts.
I'll be interested to see if a REGEX expert can provide better insight.
03-18-2015 05:41 AM
Please provide some actual sample data as close to your real data as possible (eg. as an attachment) and not only a screen shot. If these are actual superscripts then I would expect that this information must be stored somewhere in the string (so when looking at the actual hex values used) - and if this is the case then we can look for such hex values to identify your superscript stuff. But in order to figure this out we need actual data from you.
Looking at your screenshot: Would it also be possible to simply search for "1st", "2nd", "3rd", "<any other single digit or more than one digit>th"?
03-18-2015 06:43 AM
SAS knows of no superscription in it's data, character variables are just strings of bytes.
Any superscription that you see comes from output formatting, not from the data.
Can you show the SAS code that produced this: