Previous Topic: DEBIT Statement

Next Topic: DEVADDR Statement


DESCRIPT Statement

The DESCRIPT statement is optional. When selected, it provides a description of summary line information. Refer to DE ID 02 in the Output Data Elements Table later in this section.

The summarization level defines which sort control break the DESCRIPT statement refers to. For example, you can select job class as the major sort control field. CA JARS summarizes the accounting data and prints a summary line for all processing in each job class and a final summary line for all classes combined. To clarify the report, you can define a summarization description for each control break or summary line. In this example, you might prepare the following set of DESCRIPT statements:

position   1         2         3         4         5             8
  1........0.........0.........0.........0.........0..        ...0
  ADESCRIPT1A       CLASS A JOBS
  ADESCRIPT1B       CLASS B JOBS
  ADESCRIPT1C       CLASS C JOBS
      .
      .
      .
  ADESCRIPT1        UNIDENTIFIED CLASS

The description control field and a sort control field must match character for character to associate the correct description with the corresponding sort control break. The sort control fields may be a maximum of 32 characters in length. Unused characters in the description control field are padded with trailing blanks. The description control field must be exactly the same as the first eight characters of the sort control field.

You may need the same DESCRIPT statements for different report formats, the only variation being the summarization level. In one report you might use job class as the level-1 sort control field, as in this example, and in another report use job class as a level-2 or -3 sort control field. The only difference in the two sets of DESCRIPT statements would be the set code and the summarization-level indicator.

You may, however, leave the set code blank and define the summarization level as 0, which makes the summarization description available to all reports and to any control break -- not just the level-1 break as in the example.

You must use the any level summarization level with caution. Certain reports, for example, are sorted by:

In such cases, you must specify summarization level to make sure that the right description appears at the right level.

Note: If fewer than five sort levels are used in a report, you may identify them as 1, 2, and 3; 2, 3, and 4; or even 1, 4, and 5.

Level numbers indicate relative positions; the precise number selected is only important because the level number on the DESCRIPT statement must match that defined on the SORT statement.

Variable Description Feature

You may find that at a particular sort level, there are a number of fields whose descriptions are almost the same except for a small amount of variable information. For example, at level 1 a report might sort through Class A Jobs, Class B Jobs, and so on for 20 or 25 job classes. In this case, rather than code a separate DESCRIPT statement for each control break or summary line, you may prepare a single DESCRIPT statement and, by using the Variable Description feature, transfer the job class automatically from the sort control field into the description field.

You may invoke this feature by replacing the first four characters of the description control field with four asterisks. These indicate that the next four positions determine what will be transferred from the sort control field.

The four asterisks are followed by:

The following example illustrates a typical use of the Variable Description feature:

           Summarization Level Invokes
               Variable Description Feature
                 │
                 │
  position   1   ▼     2         3         4                           8
    1........0.........0.........0.........0...........          ......0
    ADESCRIPT1****0711CLASS X JOBS
                      └──────────┘
                            ▲
                            │
                This appears on every summary
                line at this sort control level.

This statement defines the format for Report A. The summarization level is 1, followed by the four asterisks that invoke the Variable Description feature. The variable information (job class, in this case) located in the first position of the sort control field, is transferred to position 7 of the description field (overlaying the x appearing in the example).

Note that DESCRIPT statements using the Variable Description feature and those that contain blank description control fields share one characteristic: they terminate the DESCRIPT statement searching logic, and are used regardless of the current contents of the sort control field. DESCRIPT statements with blank description control fields are intended to be used for catchall or miscellaneous descriptions and should follow all DESCRIPT statements with nonblank description control fields.

Position

Field Length

Field Name

Notes

1

1

Set Code

Optional

2-9

8

Statement Type

DESCRIPT

10

1

Summarization Level 0:

Any level

1: 1st sort level (most general level)
2: 2nd sort level
3: 3rd sort level
4: 4th sort level
5: 5th sort level (most detailed level)

11-18

8

Description Control Field

Matches Sort Control Field unless Variable Description feature is used. In that case:

Position Length Notes

11-14 4 **** asterisks

15-16 2 TO location in DESCRIPT
Field, relative to 1

17 1 Number of characters to
be moved

18 1 FROM location in Control
Field, relative to 1

(Refer to Variable Description feature)

19-38

20

Description Field

Refer to DE ID 02 in the Output Data Elements Table

39-80

41

Reserved

Not used