Specifying tape input or output

When you use Z Data Tools tape options, you can process tape data in one of two ways: basic tape or labeled tape:
Basic tape
With basic tape processing, you work with tape files and tape blocks. The first tape mark after a data record or after the leading tape mark is treated as the end of a file. Basic tape functions cannot process multivolume input tape files. No tape label processing is performed; tape label sets are processed as ordinary tape files.
You can move the tape forward or backward by a number of physical records or a number of tape files. Tape input is read from the current position of the input tape, and tape output is written to the current position of the output tape.
Note:
  1. For output tapes, you can position the tape before the last tape mark of a file if you want to extend the tape file.
  2. To process a labeled input tape without label processing, position the tape at the first data record; for example, by using Forward Space File (option 4.15.2) to skip the tape label file.
  3. If the first record read is a tape mark, Z Data Tools considers it a leading tape mark and continues. To copy a null file correctly, position the tape in front of the tape mark, which is then treated as a leading tape mark. To copy consecutive files (including null files) from a multifile input tape, use Backward Space Record (option 4.15.3) before each copy command.
  4. At the end of tape, Z Data Tools writes two tape marks to indicate the end of volume, unloads the full tape, and requests the mounting of another volume on the tape output device. You can thus create an unlabeled multivolume tape file.
  5. For tape functions that cross tape marks and for tape output functions, BLP or NL processing is recommended.
Labeled tape
For labeled tape processing, you specify a file ID. An input tape must be positioned in front of the specified label set. (If the file IDs do not match, the function ends with an error.) An output tape must be positioned at the beginning of a tape or immediately after a labeled file.

Z Data Tools processes SL and AL (ANSI) labels. On input, the label format is recognized automatically. For output, use the TAPELBL entry field from the Set Processing Options panel to select the label type.

Labeled tape processing is specified when the tape is opened (during interactive allocation). Only the following options are enabled for output label processing:
  • Create Tape Data (option 4.7)
  • Sequential Data to Tape (option 4.2.7)
  • VSAM to Tape (option 4.2.6)
Note: Not all combinations of Z Data Tools keyword values are supported by the underlying operating environment. For information on supported combinations, see your operating environment documentation.

You can specify tape input or output as follows:

  1. Specify a ddname for the tape unit.
  2. For an output tape, optionally specify a tape mode code, as shown in Tape density and mode values. By default, Z Data Tools does not change density, and uses buffered write mode where applicable.
  3. If the ddname is not allocated, you are asked for allocation information.
The first Z Data Tools option that uses a tape opens the tape. If the DDNAME you specify is not allocated, Z Data Tools prompts for the information required by displaying the Tape Allocation panel shown in Figure 1. Z Data Tools then dynamically allocates and opens the tape. The tape remains open until you rewind and unload it using Tape Rewind-Unload (option 4.15.6) or exit from HFM.
  • You must specify the unit. Other panel input depends on the specified label value. When you use any tape options to process multiple files (that is, go over tape marks), or any tape output options, BLP or NL processing is recommended. (Z Data Tools basic tape output options do not create labeled tapes).
  • If you specify BLP (provided you are authorized), the VOLSER is not verified and any data set name is ignored. If input tape label processing is desired (SL or AL), both the VOLSER and data set name are required and must match. To allocate a scratch tape for output (nonspecific request), omit the VOLSER.
Figure 1. Tape Allocation panel
 Process   Options   Help
────────────────────────────────────────────────────────────────────────────────
 Z Data Tools            Tape Allocation

 Tape Allocation:
    DDNAME to use  . . WHICHTAP
    Volume serial(s) .___________________________________
    Unit . . . . . . . ___          device number, generic, or group name
    Label value  . . . SL_          SL, NL, AL or BLP
    Data set name  . .____________________________________________
    Sequence number  . ____         relative position of data set on tape
    Expiration date  . ________     yyyy.ddd, leave blank if none desired
    Open for write . . NO_          NO or YES
    Disposition  . . . MOD_         OLD, MOD, NEW, or CAT (for NEW,CATLG)








 Command ===> _________________________________________________________________
 F1=Help      F2=Split     F3=Exit      F4=CRetriev  F7=Backward  F8=Forward
 F9=Swap     F10=Actions  F12=Cancel
When you allocate a tape, you are asked for the following information:
DDNAME to use
The ddname for the tape unit
Volume serial
The actual volser (which is verified if label processing is requested), or an external number to be used for mounting the tape if you do not know the actual volume serial (which requires BLP). For example, you might use Tape Label Display (option 4.8) to find out the actual volume serial number.

To access a volume set, specify up to five volsers in parentheses, for example: (FMO005 FMO006 FMO007). Volume sets are supported by the Tape Label Display (option 4.8), Tape to Labeled Tape (option 4.2.3), and basic tape output functions.

To access a scratch tape (a non-specific volume request), do not enter a volser. The tape should not be write-protected, and the operator might need to confirm that the tape can be used. The tape is opened using OPEN=OUTIN, so that the tape can later be used for input if desired.

Unit
Tape unit number. You can respond with a device number, device type (generic name), or group name (symbolic name).
Label value
SL for standard label processing (the default), AL for ANSI label processing, BLP for bypass label processing, or NL for no labels.

If Z Data Tools is running APF-authorized, BLP is set internally for some functions if the user has the appropriate authority. BLP is reset when the function ends.

Data set name
The name of the tape data set that you want to work with, if label processing is used.
Sequence number
The relative position of a data set on the tape.
Expiration date
The expiration date for the data set.
Open for write
Specify YES to access a tape in read/write mode. The tape should not be write-protected, and the operator might need to confirm that the tape can be used. The tape is opened using OPEN=INOUT, so that the tape can be used for output if desired but labels are not rewritten during open.
Disposition
Data set status. Default is MOD.
OLD
The file already exists.
MOD
If the file already exists, add records to the end of the file; otherwise create a new file.
NEW
Create a new file.
CAT
If the step terminates normally, the file is cataloged.

If the Z Data Tools session abends, you might need to use the TSO FREE command to remove any Z Data Tools allocations.

Note: You can also allocate tapes outside Z Data Tools. For example, you might want to use allocation parameters that you cannot specify within Z Data Tools.

If you use options that are not enabled for output label processing, the tape remains open until you rewind and unload it (using Tape Rewind-Unload) or exit Z Data Tools. If you use an option that is enabled for output label processing (Create Tape Data, Sequential Data to Tape, VSAM to Tape), the tape is rewound and unloaded after the file is closed and the task has completed.