IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

FTP from mainframe to UNIX server without loss of data


IBM Mainframe Forums -> All Other Mainframe Topics
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
sanjaygkk
Currently Banned

New User


Joined: 27 Oct 2006
Posts: 1
Location: Bangalore

PostPosted: Fri Mar 09, 2007 2:08 pm
Reply with quote

HI all

MY question is i am able to FTP it , but some of the data giving junk value , that too only for COMP fileds , so how to FTP without the loss of data
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3156
Location: Tucson AZ

PostPosted: Sat Mar 10, 2007 4:02 am
Reply with quote

Do you understand what code pages are?
An "A" in EBCDIC will translate to an "A" in ASCII without any problem, but a lot of the possible byte configurations translate not so well.
Data is of the form of character, packed decimal and binary; character data translate well, packed and binary does not.
You have to decide, either transfer without translation and the receiver will have to translate the character data or transfer with translation and the sender will have to "un-binarize" and un-pack the numeric date.
Your choice, what'ch go'na do? icon_smile.gif
Back to top
View user's profile Send private message
Devzee

Active Member


Joined: 20 Jan 2007
Posts: 684
Location: Hollywood

PostPosted: Sat Mar 10, 2007 4:45 am
Reply with quote

I would suggest to translate data with all COMP fields to NUMERIC and then FTP the file.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Sat Mar 10, 2007 6:57 am
Reply with quote

Hello,

To successfully and easily transmit mainframe data to unix (or windows) make sure that the file to be transmitted is entirely in text format.

Due to the way individual bytes are converted from EBCDIC to ASCII you will get erroneous/unpredictable results if you transmit any packed or binary data.

Several bit patterns translate into ascii control characters and the target system does not know a "real" control character from a "fake" one. One of the most common is an embedded x'09' (which happens often in packed numbers) and is a tab-character on many target systems.

There are not many applications that do this any more, but if your application chose to use bit-switches (because there were a high number of fields whose value was restricted to yes/no, and disk space was expensive then), those will not transmit correctly.

To repeat, you will be way ahead if you expand all of your numbers on the mainframe and send a clean file to the ascii system.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> All Other Mainframe Topics

 


Similar Topics
Topic Forum Replies
No new posts How to save SYSLOG as text data via P... All Other Mainframe Topics 4
No new posts FTP VB File from Mainframe retaining ... JCL & VSAM 8
No new posts Store the data for fixed length COBOL Programming 1
No new posts Mainframe openings in Techmahnidra fo... Mainframe Jobs 0
No new posts Data set Rec-Cnt and Byte-Cnt Testing & Performance 2
Search our Forums:

Back to Top