Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Suppress Carriage Return Character during FTP

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> All Other Mainframe Topics
View previous topic :: :: View next topic  
Author Message
vgmurthy

New User


Joined: 19 Feb 2008
Posts: 8
Location: Chennai

PostPosted: Tue Apr 26, 2011 3:32 am    Post subject: Suppress Carriage Return Character during FTP
Reply with quote

Hello Everyone!

Need your assistance on an FTP Issue.

The background:
We use FTP to transfer files from Unix system to Mainframe host. My Mainframe Job logs into Unix Server and GET the file onto a Mainframe flat file. The source for this Unix box is a "File System" box

The Issue:
One of the file at Unix uses x'0D' as a delimiter. (We at Mainframe host have no control on what could be sitting on the file). When I try extracting the file from the Unix box, the x'0D' is intepreted as Carriage Return(CR) character and the rest of the data is written on to the next line.

Help:
I tried the following locsite options:
UNICODEFILESYSTEMBOM=ASIS/NEVER/ALWAYS
SBSENDEOL=NONE
MBSENDEOL=NONE
NOREMOVEINBEOF

Can anyone please throw some light on how to stop interpreting the CR character, to avoid data being written to next line?.

I have set the TYPE as ASCII for FTP transfer. Even tried to change the format to Binary, but in vain. The extracted dataset looks holding bad data.

I have attached my input file and output file for your reference.

Appreciate your help.
Thanks,
Venu

[img][/img]
Back to top
View user's profile Send private message

Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8057
Location: East Dubuque, Illinois, USA

PostPosted: Tue Apr 26, 2011 5:29 am    Post subject:
Reply with quote

MBSENDEOL and SBSENDEOL only have a bearing when sending data to the server -- using the GET command means neither of them will do anything.

What does the file have for end of line if X'0D' is used in other ways? You could try setting up a translate table to convert the X'0D' to spaces but you need to know what the end of line character is. Alternatively, you may have to reconstruct each line from the multiple lines on the mainframe.

The best solution would be to get the file on the Unix server to start using standards (like spaces instead of X'0D' for separators), but the best solution is not always possible.
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4648
Location: Raleigh, NC, USA

PostPosted: Tue Apr 26, 2011 5:40 am    Post subject: Reply to: Suppress Carriage Return Character during FTP
Reply with quote

When confronting this situation in the past, dealing with ANSI EDI data that unfortunately used a LF as a segment terminator, the best solution I could come up with is to FTP the data in binary mode, wrapping the file into fixed-length records. Then, I'd use Unix System Services to convert the data from ASCII to EBCDIC, and then write a program to un-wrap the data disregarding and/or converting the LF to some other character. Sorry.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> All Other Mainframe Topics All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts QUESTION: RETURN CHANNEL pahiker CA Products 21 Thu Apr 20, 2017 12:31 am
No new posts JCL to Set Return code based on DB2 S... vinu78 DB2 17 Mon Mar 13, 2017 9:47 pm
No new posts the use of 'B3'x character in a panel Pedro TSO/ISPF 1 Thu Feb 16, 2017 3:09 am
No new posts MAX-RC 88 and Return code 606 in DFH0... lind sh CICS 2 Tue Jan 24, 2017 1:23 pm
No new posts How to Capture the Max return code of... anilkumar922 All Other Mainframe Topics 2 Thu Jan 12, 2017 12:02 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us