An update on this...

I've concluded that I haven't described iconv's behaviour correctly below. In my defence, this is an incredibly confusing area to work in. What you see is not always what it seems...

iconv does appear to be implementing some for of bidirectional algorithm and I think it's doing it OK. But I would still like to know if the environment variables implemented on z/OS are available on IBM i?



"Peter Clifford" <peter.clifford@xxxxxxxxxxxxxxxxxxxxx> wrote in message news:mailman.13032.1322386339.2520.midrange-l@xxxxxxxxxxxx...
Hi. Wondering if anyone out there can help.

I am trying to convert some bidirectional text (a combination of Arabic and English) to UTF16 and/or UTF8 using iconv and am getting unsatisfactory results. The input data is encoded in EBCDIC 420. The Unicode output is correctly converted, in terms of character-level conversions, but it seems to me that the entire set of characters (both Arabic and English) is reversed.

It's hard to describe what I mean, but it's as if:

EBCDIC 420: The TV station "areezajlA"


Unicode: "Aljazeera" noitats VT ehT

which is correct so far as the Arabic is concerned, but not the English.

Now, I believe this means that iconv on IBM i is not implementing the Unicode bidirectional algorithm which (as I understand it) should allow iconv to recognize which parts of the text are RTL and which LTR and handle them accordingly.

A bit of Googling led me to this:

which suggests that iConv on z/OS supports some environment variables which can tell it to implement the bidirectional algorithm (I think).

So far, I can find nothing to indicate that these are supported on IBM i. Anyone know?


This thread ...

Return to Archive home page | Return to MIDRANGE.COM home page