× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Brad,

Do you specify CCSID or code page in the open() API? If you use flag 
O_CCSID, you specify the CCSID; if you use flag O_CODEPAGE, you specify 
the code page, which is used to derive a CCSID.

Joep Beckeringh






"Brad Stone" <brad@xxxxxxxxxxxx>
Sent by: 
rpg400-l-bounces+j.beckeringh=pantheon-automatisering.nl@xxxxxxxxxxxx
26-10-2006 05:04
Please respond to RPG programming on the AS400 / iSeries
 
        To:     RPG programming on the AS400 / iSeries 
<rpg400-l@xxxxxxxxxxxx>
        cc: 
        Fax to: 
        Subject:        "Conversion Error" when opening Stream File


This sort of falls back to the DBCS issues I'm having with
a client.

Anyhow, we have physical file containing all text, and a
CCSID of 935.  One field in the PF of type "O".  The text
contains some DBCS chinese characters.

Now, we're trying to read this file and write it to a
stream file using the IFS APIs. 

For the open API we're specifing a CCSID of 1381.

But, on the open API call, we're getting a "Conversion
error" message and the job fails.  The error actually shows
the line number of the error as the definition for the open
API itself instead of the actual call, though.  (odd, I
thought it would have been on the call).

Now, we've succesfully taken this PF and copied it to a
stream file using CPYTOIMPF, and that works fine.  We
specify *STDASCII as the "to" CCSID and it automatically
creates it as 1381. 

But, we need to use a program to do the conversion to a
stream file because we do maniuplate some of the data as
we're going through it.

This generic "conversion error" is sort of driving me nuts,
though, as I can't find any information on it except "the
CCSID is invalid".

Well, if CPYTOIMPF can do it, shouldn't I be able to?  :)

Thanks for any assistance with this.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.