UNIX-Mainframe FTP



IBM OS/370, MVS, OS/390, Linux, TPF, VM/CMS, VM/ESA, VSE/ESA, z/VM, z/VSE, z/OS, z/OS.e etc...

UNIX-Mainframe FTP

Postby raghav08 » Wed Jun 29, 2011 12:22 pm

Hello,

The UNIX based application sending a flat file to mainframe using FTP. The file contains some currency symbols like Pound, Euro etc.

But if I open the FTP received dataset in mainframe, those currency symbols appears with additional characters even though file sent in EBCDIC format.

Please let me know how to address this issue.

Thanks
raghav08
 
Posts: 18
Joined: Wed Oct 27, 2010 5:10 pm
Has thanked: 0 time
Been thanked: 0 time

Re: UNIX-Mainframe FTP

Postby Robert Sample » Wed Jun 29, 2011 2:56 pm

Please let me know how to address this issue.
Since you did not provide any examples of what you meant by "additional characters", we cannot tell you how to address the issue. Without something to look at, what do you expect us to do?

Further, standard EBCDIC on a mainframe is code page 037. This code page does not contain the Euro symbol, which is found on code page 1140 (among others). If your file on the mainframe is using code page 037, you will NEVER, under any circumstances, see a Euro currency symbol. Your best bet, considering code pages can be a very complicated subject and at least partly determined by how the site is configured, would be to talk to your site support group and get their assistance in making sure your file is using the right code page.
Robert Sample
Global moderator
 
Posts: 3720
Joined: Sat Dec 19, 2009 8:32 pm
Location: Dubuque, Iowa, USA
Has thanked: 1 time
Been thanked: 279 times

Re: UNIX-Mainframe FTP

Postby raghav08 » Wed Jun 29, 2011 4:59 pm

Thanks for your reply.

I don't know much about code page numbers, but I edited a test dataset and inserted x'B1' and x'B2' and saved.I can see the Pound & Yen symbols, but not Euro (x'20'). x'20' diplayed as '.' (dot)

Thanks.
raghav08
 
Posts: 18
Joined: Wed Oct 27, 2010 5:10 pm
Has thanked: 0 time
Been thanked: 0 time

Re: UNIX-Mainframe FTP

Postby Robert Sample » Wed Jun 29, 2011 5:59 pm

Code page 1140 shows the euro symbol as X'9F', not X'20'. X'20' in EBCDIC is down in the communications control characters and almost certainly is NOT the euro symbol on any code page since it has been assigned a different value for probably 40+ years.
Robert Sample
Global moderator
 
Posts: 3720
Joined: Sat Dec 19, 2009 8:32 pm
Location: Dubuque, Iowa, USA
Has thanked: 1 time
Been thanked: 279 times

Re: UNIX-Mainframe FTP

Postby raghav08 » Wed Jun 29, 2011 6:19 pm

In practice,is there any chance like currency symbols (Pound,Euro,Yen etc) are represented using two byte format & rest of characters are in single byte in one record.

Please advice
raghav08
 
Posts: 18
Joined: Wed Oct 27, 2010 5:10 pm
Has thanked: 0 time
Been thanked: 0 time

Re: UNIX-Mainframe FTP

Postby Robert Sample » Wed Jun 29, 2011 6:23 pm

Theoretically, DBCS could do this. Shift-in (X'0F') and Shift-out (X'0E') are used for DBCS but I've never had to deal with DBCS and that's about the extent of my knowledge.
Robert Sample
Global moderator
 
Posts: 3720
Joined: Sat Dec 19, 2009 8:32 pm
Location: Dubuque, Iowa, USA
Has thanked: 1 time
Been thanked: 279 times

Re: UNIX-Mainframe FTP

Postby raghav08 » Wed Jun 29, 2011 6:38 pm

I had glance about UTF concepts,but still confusion on UTF-8 & UTF-16. Suppose a character string represented by UTF-16, does it mean that each charater field takes 2 bytes mandatory or it may take 1 or 2 byte based on character type.

I'm just trying to correlate is there any chance like those currency symbols are in UTF-16 and rest are all uses one byte.

This issue is real nightmare, please help
raghav08
 
Posts: 18
Joined: Wed Oct 27, 2010 5:10 pm
Has thanked: 0 time
Been thanked: 0 time

Re: UNIX-Mainframe FTP

Postby BillyBoyo » Wed Jun 29, 2011 8:05 pm

If you are getting all your currency symbols on the Unix side (which I assume you are) then there will be some way to do it.

Firstly, there is (I expect, maybe Robert can confirm) the possibility of having your own specific code-page. I had a similar problem a few years ago, with a Tandem machine using UK ASCII, COMMS gear using European ASCII and Mainframe using American EBCDIC(!).

We had two and theree character alpha codes for currencies, but no-one (before I worked there :-) ) gave any thought to currency symbols in stock names, which were scrambled daily.

Once everything was in line, everything worked. This was DOS/VSE, but I imagine the same priciple.

So, if you can get your own code page (and remember about going back, just so you're ready for files in the other direction) your problems will be over.

So, first step is some research, then a polite request to your systems' guys.

If you can't get anywhere that way, then there will be other ways.

When you do checking of solutions, use a single record file with values from 00 to 7F or FF (depending on the ASCII) so that you can see what will happen to every byte. By all means set up the file and try it with UTF-16.
BillyBoyo
Global moderator
 
Posts: 3804
Joined: Tue Jan 25, 2011 12:02 am
Has thanked: 22 times
Been thanked: 265 times

Re: UNIX-Mainframe FTP

Postby raghav08 » Thu Jun 30, 2011 11:34 am

Thanks for your reply, let me find the code page details for normal characters & special currency symbols from both UNIX & Mainframe systems.

I will update you the status.
raghav08
 
Posts: 18
Joined: Wed Oct 27, 2010 5:10 pm
Has thanked: 0 time
Been thanked: 0 time

Re: UNIX-Mainframe FTP

Postby Robert Sample » Thu Jun 30, 2011 3:27 pm

Firstly, there is (I expect, maybe Robert can confirm) the possibility of having your own specific code-page.
An FTP transfer can use its own translation table, and that translation table is built from the sending and receiving code pages. The details are in the Communications Server bookshelf, IP User's Guide manual I believe. Search the manual for TCPXLBIN -- and plan on getting your site support group to help you, as code page translation tables can be complex.
Robert Sample
Global moderator
 
Posts: 3720
Joined: Sat Dec 19, 2009 8:32 pm
Location: Dubuque, Iowa, USA
Has thanked: 1 time
Been thanked: 279 times

Next

Return to Operating Systems

 


  • Related topics
    Replies
    Views
    Last post