Is ZFile capable of updating a Tape file in place?

General discussion on the JZOS batch launcher and toolkit
Post Reply
ual
Posts: 3
Joined: Tue Jun 07, 2011 2:47 pm

Is ZFile capable of updating a Tape file in place?

Post by ual »

I have a Tape file and would like to update one-block-of-data in place without having to recreate the entire Tape. I was Experimenting with ZFile.xxxPos() to point to specific location within the Tape and at a later time update its contents in place but I am getting following error. I know ZFile.xxxPos() works on Disk files and not sure about Tape files. Please advice.

com.ibm.jzos.ZFileException: //DD:OUTPUT: fopen() failed; EDC5088I An invalid open mode was specified for the current device.; errno
=88 errno2=0xc00b0352 last_op=43 errorCode=0x4
dovetail
Site Admin
Posts: 2022
Joined: Thu Jul 29, 2004 12:12 pm

Re: Is ZFile capable of updating a Tape file in place?

Post by dovetail »

The ZFile constructor is a thin wrapper around the IBM C Library fopen() function.

You can lookup the errno2 (using the IBM bpxmtext command):

Code: Select all

bpxmtext c00b0352 

JrEdc1opsEdevmode02: The filename argument passed to fopen() or freopen()
specified ddname syntax that referred to a tape data set, but the mode
argument specified update. This failure occurred trying to open a tape data
set. 

Action: Correct the mode argument. A tape data set cannot be opened in update
mode. 

Source: edc1opst.c
This is a documented limitation in the IBM C/C++ Programming Guide.
ual
Posts: 3
Joined: Tue Jun 07, 2011 2:47 pm

Re: Is ZFile capable of updating a Tape file in place?

Post by ual »

Thanks for the respond and for the "bpxmtext" tip.
Post Reply