Page 1 of 1

Transfer from PC to Mainframe error

PostPosted: Fri Feb 15, 2008 2:37 am
by shelliebricker
I am trying to transfer a flat file that is 801 characters long from the pc to the mainframe. This file was created by an Oracle system written to an FTP server. It is then copied from the FTP site to a network directory. Whenever I try to do a Send from the pc to mainframe, I get an error. The file is transferred, with a TRANS04, File Transfer complete, with records segmented error. The records have a . in the 802 character and throws off the data. Does anybody know why this happens and how to get rid of the . in the last position. On the Send I've checked the Text, CR/LF and To EBCDIC options.

Thanks!!
Shellie Bricker

Re: Transfer from PC to Mainframe error

PostPosted: Fri Feb 15, 2008 3:21 am
by dick scherrer
Hello Shellie and welcome to the forums,

On the mainframe, pre-allocate the file as 802 (and maybe 803) and see what happens when you ftp over the pre-allocated file.

If you look at the uploaded data in hex, what is in byte 802?

Re: Transfer from PC to Mainframe error

PostPosted: Fri Feb 15, 2008 3:45 am
by shelliebricker
If I add a position to the file, it transfers and puts a character of . in the 802 position. The hex character in 802 position is 25.

Thanks!!
Shellie

Re: Transfer from PC to Mainframe error

PostPosted: Fri Feb 15, 2008 4:10 am
by dick scherrer
Hi Shellie,

Are you able to work with the uploaded file now?

What happens if you change the length to 803?

You might try an ftp without the cr/lf just to see what happens.

There have been several times when files created by an oracle/unix system needed special care and feeding to upload. . .

Re: Transfer from PC to Mainframe error

PostPosted: Fri Feb 15, 2008 2:25 pm
by MrSpock
5.35 LOCSIte subcommand--Specify site information to the local host:

Do not use an end-of-line sequence other than CRLF if the server is a z/OS FTP server. The z/OS FTP server supports only the CRLF value for incoming data.

Re: Transfer from PC to Mainframe error

PostPosted: Fri Feb 15, 2008 9:50 pm
by shelliebricker
When I make the file 803 characters, then the data gets segmented again. The 802 length with the cf/lf turned off works ok. I can use this, but then I will have to modify my mainframe programs to use this new length. I was just trying to avoid having to do this. What also works is editing the file before uploading. Going to the end of the first line, hitting delete and then return. This gets rid of the extra character. This is a process that we do everyday and I was wanting to find a way to avoid this type of manual intervention.

Thanks for your help!!
Shellie Bricker

Re: Transfer from PC to Mainframe error

PostPosted: Fri Feb 15, 2008 11:03 pm
by dick scherrer
Hi Shellie,

I can use this, but then I will have to modify my mainframe programs to use this new length.
How many programs use tis file? If several, you might run a sort or an iebgener to re-format the data to match the programs.

Yup, i'd surely agree that you don't want to do this manually :)