Previous Topic: DISPLAY Statement

Next Topic: EXITS Statement


EDIT Statement

Position

Field Length

Field Name

Notes

1

1

Set Code

Optional

2-9

8

Statement Type

EDIT

10-69

4
.
.
.
Up to 14 additional occurrences
.
.

Option Specification

1 to 15 occurrences of nnes where:

nn: = Output Data Element ID

(See Output Data Element Table)

e: = Data Element Edit Option

Code

s: = Summary Option Code

70-80

11

Reserved

Not used

This statement, identified by the statement type EDIT, is optional. The EDIT statement can be used to alter the way in which output data elements are edited for printing, and/or the logic applied at control breaks (summary lines).

Alternate edit and/or summary option codes may be specified for up to 15 output data elements. The available edit option codes and their interpretations are described in the following Data Element Edit Option Codes Table. The available summary option codes and their interpretations are described in the Summary Option Codes Table. The specification of an edit or summary option that is not applicable to a particular type of output data element is ignored, and the default options are used. One EDIT statement can be used globally, that is with a blank set code. This statement can be overridden for any individual report by an EDIT statement with a nonblank set code. The relative order of the statements in the input stream has no effect on this logic.

Only one edit and summary option can be in effect for an output data element even if it is specified more than once on either a DISPLAY or EDIT statement. If specified more than once on an EDIT statement, the last (rightmost) set of options apply. An exception to this is the use of the S (Sign) or E (Currency Symbol), which are additive, and may be specified in addition to a formatting type edit option.

The calculation of utilization rate and index data elements are handled as special cases by the Report Writer and the specification of alternate summary options for these types of output data elements is not recommended. If this is done, the summary option is applied to the calculated value contained in the Basic Account Record. For example, if a summary option of T is specified for the Output Data Element 78 (I/O Index), the result at each control break is the display of the total of all calculated I/O Index values from each Basic Account Record within that control break. It is unlikely that this particular number would be of much interest, but there may well be valid applications for the use of the minimum, maximum or average type summary options with these types of output data elements. Since the effect of several of the summary options is to significantly alter the interpretation of the displayed data elements, it is suggested that appropriate titles also be specified.

Data Element Edit Option Codes

Option Code

Description Code

0

Edit numbers as integers (that is, zero decimal positions)

1

Edit numbers with one decimal place

2

Edit numbers with two decimal places

3

Edit numbers with three decimal places

4

Edit numbers with four decimal places

5

Edit numbers with five decimal places

H

Edit time fields at HHHH.MM.SS or HHHHHHH.MM

D

Edit dates as DD/MM/YY

M

Edit dates as MM/DD/YY

Y

Edit dates as YY/MM/DD

C

Edit character data - normal default for most non-numeric data elements

S

Reserve low-order position for sign: =positive, - = negative*

E

Add currency symbol if space is available and not suppressed via PARMS statement*

 

Do not change - allow default option to remain in effect

* May be used in combination with other option specifications for the same output data element.

Summary Option Codes

Summary Option Code Table:

Option Code

Note

Description

T

 

TOTAL - Normal default for most numeric Output date

A

 

AVERAGE - Total divided by number of records

H

2

HIGHEST value encountered since last Control break

L

2

LOWEST value encountered since last Control break

D

2

DISPLAY edited value from last Account Record before a Control break

N

2

NO-OP - Do not display anything - default for character fields

B

3

BREAK-AVERAGE - Total divided by number of control field changes at next lower summary level

U

1

USER-AVERAGE - Total divided by accumulation of User-Count-Field

I

1

INDEX - Total divided by accumulation of CPU Time (in seconds)

E

1

ELAPSED-INDEX - Total divided by accumulation of Elapsed-Time (in minutes)

 

 

Do not change - Allow default option to remain in effect

Note:

  • Operative at detail level, as well as each summary level.
  • Only options allowable for non-numeric data-elements, thatinclude dates and times-of-day.
  • Example: Sort Field 1 = Userid, Sort Field 2 = Run Date: Result at second summary level is daily total, at first summary level is average per day, at grand total is average per different userid. See references to Output Data Element F7: Control Break Count.