Previous Topic: Field Name Cross-Reference ListingNext Topic: Report Description


Hit File Layout

The Hit File Layout includes detailed file and record information for the internally generated Hit File. This layout represents a COBOL Data Division definition and shows how the Reporting Facility expects the definition to look if the file is input to the Reporting Facility.

This technique is used to show the basic content of the file for illustration purposes. The record information includes the following:

RDW

The Record Descriptor Word standard for any variable format file. It always occupies the first four bytes of the record.

tag character

A one-character field containing the tag character assigned to the record when it was selected by a SELECT command.

sort key

Includes the report number and the internal sort key necessary after analyzing all of the CONTROL commands in the program. This allows the system to produce multiple reports in the same run with different sorting requirements for each.

variable length user fields

Represent multiple occurring groups of data, each pertaining to a specific report. Each record report group is the same length. Each variable segment listed describes the unique data necessary to print a single report.

Following is a sample of the sixth page of the report. For an example of the report header (not shown here), see Sample Report Headers).

          Assumed disk device type of Hit File                                                     ┌─────────┐                                               ►     │(3350   )│......H I T   F I L E   L A Y O U T......                                                     └─────────┘    FD  DROUT                                   DROUT:  FILE DISK SEQUENTIAL VARIABLE RECORD=         100 BLOCK=       4612                               ┌───────────────┐          BLOCK CONTAINS       │4612 CHARACTERS│   ◄Automatically calculated BLOCK/RECORD size                               └───────────────┘          RECORD CONTAINS         100 CHARACTERS          RECORDING MODE V          DATA RECORD IS HITFILE.    01  HITFILE.   ▼ Common to all Hit File records       ┌────────────────────┐       │02 RDW              │              PICTURE X(4)                 DEFINE RDW                             1 -    4 X         4       │02 TAG-CHARACTER    │              PICTURE X                    DEFINE TAG-CHARACTER                   5 -    5 X       │02 SORT-KEY.        │       │   03 REPORT-NUMBER │              PICTURE B                    DEFINE REPORT-NUMBER                   6 -    6 B       │   03 USER-SORT-KEY │              PICTURE X(15)                DEFINE USER-SORT-KEY                   7 -   21 X       2       └─────────────────────        02 REPORT-01.                      XYZ SAMPLE REPORT 01 Fields unique to Report No. 1          ┌───────────────────────┐     ►    │03 00.CUSTOMER-NAME    │        PICTURE X(24).               DEFINE 00.CUSTOMER-NAME               22 -   45 X          │03 01.CUSTOMER-SALE-ID │        PICTURE XX                   DEFINE 01.CUSTOMER-SALE-ID            46 -   47 X          │03 00.CUSTOMER-CITY    │        PICTURE X(13)                DEFINE 00.CUSTOMER-CITY               48 -   60 X          │03 01.STATE            │        PICTURE XX                   DEFINE 01.STATE                       61 -   62 X          │03 01.ZIP-CODE         │        PICTURE X(5)                 DEFINE 01.ZIP-CODE                    63 -   67 X       6          │03 01.CREDIT-LIMIT     │        PICTURE 9(6)V99              DEFINE 01.CREDIT-LIMIT                68 -   75 N2      7          │03 01.SALESMAN-ID      │        PICTURE XX                   DEFINE 01.SALESMAN-ID                 76 -   77 X       7          │03 01.CURRENT-BALANCE  │        PICTURE 9(5)V99              DEFINE 01.CURRENT-BALANCE             78 -   84 N2          └───────────────────────┘        02 REPORT-02.                      XYZ SAMPLE REPORT 02 Fields unique to Report No. 2          ┌───────────────────────┐     ►    │03 00.CUSTOMER-NAME    │        PICTURE X(24)                DEFINE 00.CUSTOMER-NAME               22 -   45 X          │03 01.CUSTOMER-NUMBER  │        PICTURE XXX                  DEFINE 01.CUSTOMER-NUMBER             46 -   48 X       4          │03 00.CUSTOMER-CITY    │        PICTURE X(13)                DEFINE 00.CUSTOMER-CITY               49 -   61 X       6          │03 00.ST               │        PICTURE X(14)                DEFINE 00.ST                          62 -   75 X       7          │03 01.ZIP-CODE         │        PICTURE X(5)                 DEFINE 01.ZIP-CODE                    76 -   80 X       8          │03 01.CUSTOMER-SALE-ID │        PICTURE XX                   DEFINE 01.CUSTOMER-SALE-ID            81 -   82 X       8          │03 01.CREDIT-LIMIT     │        PICTURE 9(6)V99              DEFINE 01.CREDIT-LIMIT                83 -   90 N2          └───────────────────────┘        02 REPORT-03.                      XYZ SAMPLE REPORT 03 Fields unique to Report No. 3          ┌───────────────────────┐     ►    │03 00.CUSTOMER-NAME    │        PICTURE X(24)                DEFINE 00.CUSTOMER-NAME               22 -   45 X          │03 01.CUSTOMER-NUMBER  │        PICTURE XXX                  DEFINE 01.CUSTOMER-NUMBER             46 -   48 X          │03 01.CREDIT-LIMIT     │        PICTURE 9(6)V99              DEFINE 01.CREDIT-LIMIT                49 -   56 N2          │03 01.CURRENT-BALANCE  │        PICTURE 9(5)V99              DEFINE 01.CURRENT-BALANCE             57 -   63 N2          │03 00.UNUSED-CREDIT    │        PICTURE S9(7)V99      COMP-3 DEFINE 00.UNUSED-CREDIT               64 -   68 P2          │03 00.CUSTOMER-CITY    │        PICTURE X(13)                DEFINE 00.CUSTOMER-CITY               69 -   81 X          │03 00.ST               │        PICTURE X(14)                DEFINE 00.ST                          82 -   95 X          │03 01.ZIP-CODE         │        PICTURE X(5)                 DEFINE 01.ZIP-CODE                    96 -  100 X          └───────────────────────┘