cancel
Showing results for 
Search instead for 
Did you mean: 

Writing a unicode file

Former Member
0 Kudos

Hi,

Our developer has been trying to develop a program to upload a spreadsheet containing Chinese characters into an internal table and then write it to a flat file in the IFS. He has tried a lot of different settings on the open statement to create a file with a unicode CCSID but it seems to always come out as CCSID 819.

There are english and chinese Characters in the spreadsheet that display in excel but when he views the file in AL11 after uploading and writing a file the characters show up as # signs.

We are running 4.7 Enterprise and it is UNICODE already so it "seems" like this should be inherant but we're stumped.

Any ideas?

Thanks,

Craig

Accepted Solutions (1)

Accepted Solutions (1)

volker_gldenpfennig
Active Participant
0 Kudos

Hi Craig,

I'm sorry to say, that I cannot believe you here ....

You have to care, that the CCSID isn't changed when only updated!!!

=> ALWAYS delete the file with delete dataset before you open it again ...

It should be pretty simple:

open dataset xxxxx ENCODING UTF-8 .

In your case, the following woudl work as well, but I would recommend utf-8:

open dataset xxxxx ENCODING default .

Regards

Volker Gueldenpfennig, consolut international ag

http://www.consolut.net - http://www.4soi.de - http://www.easymarketplace.de

Former Member
0 Kudos

Umn er ah duh ........ Ja that did it. He had the UTF-8 but not the new file.

My mind was stuck in ascii using cpy to change from one code page to another but at that point it was too late.

Thanks Volker you have made our day much better!

volker_gldenpfennig
Active Participant
0 Kudos

Hi Craig,

perfect ))

Regards

Volker Gueldenpfennig, consolut international ag

http://www.consolut.net - http://www.4soi.de - http://www.easymarketplace.de

Answers (0)