LIBRARY-ALLOC (45 bytes)

The information for dynamically allocating a tableBASE library or another dataset.

 01 LIBRARY-ALLOC.
    05 LIBRARY-SHARE-STATUS             PIC X VALUE 'S'.
    05 LIBRARY-DATASET-NAME             PIC X(44)
                             VALUE 'YOUR.PREFIX.TBASE.MAINLIB'. 

where:

LIBRARY-SHARE-STATUS (l byte) indicates how the allocated library is to be shared, and is equivalent to the DISP parameter in MVS JCL.

  • O—for exclusive access (OLD)
  • S—for shared access (SHR)

LIBRARY-DATASET-NAME (44 bytes) is the name of the dataset to be allocated.