I am doing a binary file transfer from a PC to the z/OS FTP server. Since it is a binary transfer, the records are fixed length, so I pre-allocate the file so that it will be properly divided into records on the mainframe. I used JCL to allocate the file, but nothing is loaded into the file. When I send the file, I get a message back that says the file has an invalid DSORG.
When I look at the file in TSO, it shows the Record Format show FB. If I do a DIR from FTP, the DSORG is ?. If I delete and allocate the file in TSO, then FTP sees the DSORG as FB and everything is fine. The problem is doing the allocate in JCL that somehow leaves the file in some sort of mixed state where TSO sees FB and FTP doesn't know what it is.
My work around is to allocate the file then write a dummy record to it. This seems to set the DSORG to FB when FTP sees it, and since I am replacing the file, it works out.
Here is what I use to allocate the file:
//TMP757A DD DSN=CMP.R004.@@.HLP9901.UPLD,
// DISP=(NEW,CATLG,DELETE),
// DCB=(RECFM=FB,LRECL=4024,BLKSIZE=16096),
// SPACE=(CYL,(18,1),RLSE),
// UNIT=SYSDA,VOL=SER=CMP016
Does anyone know what is going on that produces the totally inconsistent and odd mixed behavior?
------------------------------
Michael Lusicic
------------------------------