While your FTP session is active, do WRKOBJLCK <MYUSERID> *USRPRF.

Find the FTP job servicing the profile you are using. Look in the
joblog for more info about why the create failed.

However, that being said, using CRTPF without source like you are
results in an internally described file. Which is recommended
now-a-days. Have you considered creating DDS source for the file

Also, why delete/re-create? If you are PUTting from the z to the i,
FTP replaces the contents of the existing file anyway unless SUNIQUE
is on. If you're GETing on the i from the z, then you can add
(REPLACE to have the i overwrite the existing.

Charles Wilt

On Mon, Aug 31, 2009 at 10:23 AM, Laine, Rogers<rlaine@xxxxxxxxxxxxxxx> wrote:

You were correct, my problem was not predefining the target file.

Now I can move on to the next issue....

I would like to delete the target file and then define it again just in
case I need to rerun the FTP job.

When I do the delete then CRTPF together in one job it fails on the
CRTPF. Here are the statements..

 EZA1736I type i

EZA1701I >>> TYPE I

200 Representation type is binary IMAGE.

EZA1460I Command:



250 Member RMCST in file RMCST in library CONV deleted.

EZA1460I Command:


EZA1701I >>> CRTPF FILE(RMCST) RCDLEN(5650) SIZE(250000 10000)

550-Error occurred on command QSYS/CRTPF FILE(RMCST) RCDLEN(5650)
SIZE(250000 10
550 File RMCST not created in library CONV..

I tried adding the QUOTE before the delete but go the same results.

Any hints on what I'm going wrong?


-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of Simon Coulter
Sent: Saturday, August 29, 2009 9:47 PM
To: Midrange Systems Technical Discussion
Subject: Re: FTP z/os dataset to ISERIES library

On 30/08/2009, at 11:35 AM, Laine, Rogers wrote:

The record length=3615 and FB on the Z.

The file on the I is not predefined, it is defined by the FTP job.

You can determine the record length of the created file using the DSPFD

Your problem is caused by not predefining the target file. FTP doesn't
know the record length of the data being sent. The receiving FTP client
has to create a target file to hold the data. For stream files that
easy: each 'record' is ended by an EOL character (or pair) so the data
is simply dumped in the file. For fixed-length records that's harder.
The target has to guess at an appropriate record length. I think the
iSeries FTP server uses 1024 bytes. Thus 3615 / 1024 = 3 records.

What is the syntax of the TYPE command?

Run HELP within your FTP client to see this. It's a standard FTP sub-
command however not all clients support the EBCDIC option. Whether you
get anything 'helpful' depends on the quality of your FTP client.

You can also request server help by using your FTP client's remote help
function. If it doesn't provide one then use quote help.

If the target file ought to have a proper record layout then you should
use DDS or SQL to predefine it, otherwise you can use your FTP client to
create a physical file with the correct record length. See the iSeries
FTP Client help for the QUOTE subcommand and the CRTP special FTP Server

Simon Coulter.
   FlyByNight Software         OS/400, i5/OS Technical Specialists
   Phone: +61 2 6657 8251   Mobile: +61 0411 091 400        /"\
   Fax:   +61 2 6657 8251                                   \ /
                 ASCII Ribbon campaign against HTML E-Mail  / \

This E-Mail transmission (and/or the documents accompanying it)
may contain information belonging to the sender which is confidential,
privileged and/or exempt from disclosure under applicable law. The
information is intended only for the use of the individual(s) or entity
named above. If you are not the intended recipient, you are hereby
notified that any disclosure, copying, distribution or the taking of any
action in reliance on the contents of this information is strictly
prohibited. If you have received this E-Mail transmission in error,
please immediately notify us by return E-Mail or telephone to arrange
for return of its contents including any documents.

This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2019 by and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].