Previous Topic

Next Topic

Book Contents

Book Index

Defining the Levels

The instruction syntax for building the Recipient Tree is as follows:

LEVEL=xx

USER -

POS=n

LENGTH=n

{    DEFAULT=ccc }

{       POS=n

LENGTH=n

{    DEFAULT=ccc } }

.

.

.

{       POS=n

LENGTH=n

{    DEFAULT=ccc } }

{ PARENT -

PLEVEL=xx

POS=n

LENGTH=n

{    DEFAULT=ccc }

{    TRANSLATE=tabledd } }

{ ADDRESS -

POS=n

LENGTH=n

{    DEFAULT=ccc } }

{ SYNONYM -

POS=n

LENGTH=n

{    DEFAULT=ccc } }

{ SYNONYM -

POS=n

LENGTH=n

{    DEFAULT=ccc } }

END

Each LEVEL command can contain four types of paragraphs:

Table 3 LEVEL Command Paragraphs

Paragraph

Description

USER

Instructions to construct the user name. Mandatory.

PARENT

Instructions to construct the parent name. Optional.

ADDRESS

Instructions to construct the address text. Optional.

SYNONYM

Instructions to construct synonyms. Optional. Can be used more than once to construct more than one synonym for each user.

Parameters define how to process the paragraph. These parameters are repeated for the same paragraph if the data to be constructed consists of data contained in more than one string in the report line.

The use of these parameters is as follows:

Table 4 LEVEL Command Parameters

Parameter

Description

POS

Starting character position of the string in the input report. A value of 0 (zero) indicates that the default value is used. Data from the report is not used for this parameter.

The POS value is relative to the first print column of the report (that is, for the first column of the report, POS is set to 1) and does not include print control characters or variable record length values.

LEN

Length of the data extracted from the input report, starting from the character position specified in POS or from the default value if POS is set to 0.

DEFAULT

The default value. Optional. Any position in the field of length LEN from the report that is blank is replaced by the corresponding character from parameter DEFAULT.

The combined total length of the data constructed from all the repetitions of the parameters, for each paragraph, must not exceed the number of characters shown in the table below:

Table 5 Maximum Number of Characters for Paragraph Types

# Characters

Paragraph Type

8

USER

8

PARENT

52

ADDRESS

20

SYNONYM

The utility constructs the users based on these definitions and searches the Recipient Tree to see if the constructed user is already defined. If the user is not found, the utility adds the user. If the user is found, the utility updates the Recipient Tree. This utility is especially useful if the only changes required are the addition of synonyms.

Parent Topic

Building a Control-D Recipient Tree