Exporting Polish characters from iSeries

75 pts.
Tags:
CCSID
CPYTOIMPF
iSeries
V5R4. We have a client database that, for the first time, has to deal with Latin-2 characters. We have set up some sessions to use Polish configuration (code page 1153) and got around printing problems by having a separately configured printer. Now we have a problem with exporting the data to external systems (to be accessed by SQL server and TSQL (I have no other details)). The SQL server people say that they can't translate. We have tried creating a a new PF with CCSID 1153 (the norm is 285), also CPYTOIMPF with CCSID 1153 but no joy. Also tried Query/400 and VARCHAR but it will not allow CCSID 1153. CCSID 870 does not translate all characters for all Latin-2 so it is not an option. Any suggestions gratefully received. Thanks. Abby.
0

Answer Wiki

Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

Discuss This Question: 9  Replies

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.
  • bvining
    Well if the other system can't handle the conversion then my first thought would be to create a logical file over the CCSID 1153 physical file. In the logical file specify CCSID(1208) for the character fields. 1208 is UTF-8, which I'm confident the other system will be able to work with.
    7,070 pointsBadges:
    report
  • Abby70
    Thank you for this. I don't think it will help though (I did try it and we can't read the characters on our side).  I think the SQL server  will have to build something to translate from Hex. Any idea if anything like that exists?
    75 pointsBadges:
    report
  • bvining
    What do you mean by "on our side"?
    7,070 pointsBadges:
    report
  • Abby70
    I created the LF as per your suggestion and copied our data to it. I see, for example,  <ÆÂÍCwÁ               =/ÃÊC~>,?ÎC~  now whereas in my Polish config. of my normal file I have Libuše                Šafránková .
    75 pointsBadges:
    report
  • bvining
    When you say "I see" is that from the SQL server or the i? If the i, how are you looking at it? On the i you could just use the PF as the LF is for the convenience of the server.
    7,070 pointsBadges:
    report
  • bvining
    Since I had some spare time this morning I created a little environment to (I hope) mirror yours.

    I created a POLISHPF physical file using CCSID 1153 and loaded it with the same values you showed earlier. I then created a POLISHLF logical file over POLISHPF with all character fields re-tagged as CCSID 1208.

    I then changed my job CCSID to 65535 and using STRSQL ran Select * from POLISHLF. What I got was essentially what you did, the raw UTF8 code points.

    I changed my job CCSID to 1153 and ran Select * from POLISHLF. I got back the data in "correct" form.

    Using either CCSID I got back the "correct" data with Select * from POLISHPF.

    I suspect you were testing in a job that had a CCSID of 65535 in effect. And in that case the system will just give you UTF8 data in raw form (which is what it looks like you were getting).
    7,070 pointsBadges:
    report
  • bvining
    And for completeness I'll add that when I changed my job CCSID to 37 and ran Select * from POLISHLF then I got back the expected characters when the character was defined in CCSID 37 and a substitution character (x'3F', generally a reverse image blob) for those characters that do not exist in CCSID 37.
    7,070 pointsBadges:
    report
  • Abby70

    Thanks so much for this; I shall certainly try it. However, just to clarify: we will have various client data typed on both Latin-1 and Latin-2 keyboards and the output sent in a single file from i-series to SQL server so the assumption has always been that the SS people will have to check whether a record is Latin-1 or Latin-2 and change the CCSID or something. Are you saying that they won't have to do that?

    I asked a tester to check the file I sent. They see  what I would see if I use a 'normal' configuration -  'Libuæe ~afránková'

    75 pointsBadges:
    report
  • Abby70
    I should add that I asked a tester on SQL Server to check the file I sent.
    75 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

Thanks! We'll email you when relevant content is added and updated.

Following

Share this item with your network: