Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

reading unicode into SAS.

Status
Not open for further replies.

steve468

Programmer
May 3, 2007
2
US
I have a comma delimited file with unicode. The files come out from microsoft software. I am told that the unicode should be ucs2. I installed the additional software to read in the unicodes, I added encoding=ucs2 to my sas startup file. I have tried proc import, input statements but nothing has worked. I run a proc print(switching to html output) and its still garbage. Does anyone have any suggestions. Thanks in advance.
 
Is the unicode UTF-8? SAS can read the Unicode data but can't display it properly. You need to use the $UTF8X. informat.
You still have to ask yourself what are you trying to accomplish? If you need to analyze the unicode text as data then you will need to convert the data to a set of SAS compliant data values (unicode is not supported in this way). If you need the unicode to display on a web page without any mods to the data you could just read it in and 'dump' the data back to a web page.

Let me know
KLaz
 
I was told the data was be UCS2 encoding. All I am doing is reading the data merging it with other files. It's a file with japanese text in it. So basically I have to read in the data, make sure it's read in correctly, create a SAS file and pass it on. Doesn't sound too hard but it is.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top