Hi
Hoping to get some help. Is there a way to create a dataset that convert from Maori to Māori?
data one;
length name $30;
input name;
datalines;
Maori
;
run;
And do you have a list of words that match cafe to café?
é uses an acute accent by the way. A macron is horizontal, as in Māori.
Use the TRANWRD function
If this fails you'll have to use K functions. Sorry I can't test as I don't have UTF8 handy. KTRANWRD doesn't exist, so you'll have to do something a bit more convoluted.
There is no need for KTRANWRD() as TRANWRD() already handles replaces strings with strings that have a different number of bytes.
Thanks!! Threw an error but almost there I think. Any help will be much appreciated.
if Ethnic_group="Maori" then Ethnic_group="Māori";
Error:
An error occurred executing the workspace job "XXX".
Integration technologies failed to submit the code. [Error'
Failed to transcode data from U_UTF8_CE to U_LATIN1_CE encoding because it contained characters which are not supported by your SAS session encoding. Please review your encoding= and locale= SAS system options to ensure that they can accommodate the data that you want to process.
You use wlatin1 encoding.
This encoding does not know what character ā is. It cannot store it.
You need your SAS session to use another encoding, probably UTF8.
Encoding is a SAS startup option, and it will also change the encoding used by your SAS data sets.
This is probably over cautious, but is also comprehensive https://documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/movefile/n06qan4j3ffr6fn11bs4q11r8r56.htm
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 25. Read more here about why you should contribute and what is in it for you!
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.