• Aucun résultat trouvé

characters in length

Dans le document Information Management System/360 for the (Page 75-79)

\

)

The PCB is a set of contiguous fields that provide the application program with the ability to make Data Language/I calls supplying the following information:

• The name of the data base to be processed

• The specification of the Data Language/I functions that will be used

• Indications of the types of segments to be processed

• Areas for receiving status responses from Data Language/I

No initial values are defined in a PCB in the linkage section. The values for a PCB exist in the Program Specification Block (PSB) and are fixed at PSBGEN time. Under IMS/360, there are two types of PCB's: one type is for a data base, and the other is for an online terminal.

PCB for a Terminal

The requirements for this type of PCB are as follows. The first entry is at the first level and is the name of the PCB. The additional entries for this PCB are at the second level. The second entry is the logical terminal name, which must be a maximum of eight characters in length. If this name is less than eight characters in length, it must be padded with blanks to eight positions. The next entry is a reserved field for Data Language/I use and must be two characters in length. The following field is the status code feedback area and must be two

characters in length.

For input terminals, one additional field is required. This is the

input prefix and is

tw~lve

characters in length.

(

(

68.2

,

'I

/

)

\

COBOL Example

The following COBOL example would be found in the linkage section of the data division. This example is for either an input or an

input-and-output teleprocessing terminal.

01 02 02 02 02

INOUT-PCB.

IO-TERMINAL PICTURE X(8).

IO-RESERVE PICTURE XX.

IO-STATUS PICTURE XX.

IN-PREFIX.

03 FILLER PICTURE X.

03 I-JULIAN-DATE PICTURE S9(5) COMPUTATIONAL-3.

03 INPUT-TIME PICTURE S9 (7) COMPUTATIONAL-.3.

03 FILLER PICTURE X(4).

Time is in two positions for hours" minutes, and seconds; and one position for tenths of seconds.

PL/I Example

The following PL/I example would be found in the descriptive

statement parts of the PL/I problem program. This example is for either an input or an input-and-output teleprocessing terminal.

DECLARE 1 2 2 2 2

INOUT_PCB,

IO_TERMINAL CHARACTER(8), IO_RESERVE BIT(16), IO_STATUS CHARACTER(2), IN PREFIX,

3 - PRE DATE 3 PRE-TIME 3 PRE:MSG_COUNT

FIXED DECIMAL ( 7

I,

0) ,

FIXED DECIMAL ( 7r, 0) , FIXED BINARY(31,0):

A terminal that is used purely for output would have a PCB similar to the one above, but without the last level-two and level-three lines.

The input prefix has no meaning for output messages.

PCB for a Data Base

The PCB provides specific areas used by Data. Language/I to advise the application program of the results of its calls. At execution time, all PCB entries are Data Language/I-controlled, where control means the exclusive authority to change the contents of a PCB entry. The programmer exercises his options as to what goes into the PCB at PSB generation time.

The following fields comprise a PCB for a data base:

1. Name of the PCB - This area refers to the entire structure of PCB entries and is used in program statements.

2. Name of Data Base Description - This field provides the DBD name from the library of Data Base Descriptions. It contains

character data and is eight bytes long.

3. Segment Hierarchy Level Indicator - Data Language/I loads this area with the level number of the lowest segment encountered in its attempt to satisfy a program request. When a retrieve is successfully completed, the level number of the retrieved segment is placed here.. If the retrieve is unsuccessful, the level

number returned is that of the last segment, along the path to the desired segment, that satisfied the segment search argument.

70

This field contains character data; i t is two bytes long and is a right-justified numeric.

4. Data Language/I status Code - A status code that indicates the'"

results of a Data Language/I call is placed in this field and remains here until another Data ,Language/I call uses ~his PCB.

(Specific status, codes are discussed with their associated calls in a later section of this manual.) This field contains two bytes of character data. When a successful call is executed, this field is returned blank or with a warning status indication..

5. Data Language/I Processing options - This area contains a character code which tells Data Language/I the kinds of calls that will be used by the program for data base processin'g.. This fieid is four bytes long. Only one of the following processing options may be specified in a particular PCB. It is

left-justified to the first byte of the four-byte field,. The remaining three bytes are reserved.

possible values for the processing options are:

G - for get function

A - for get, delete, insert, and replace functions

L - for loading a hierarchical indexed sequential or hierarchical sequential data base

If the delete, replace, or insert option is specif,ied for a hierarchical indexed sequential data base, A must be used.

The only valid options for a hierarchical sequential data base are G and L, and they are mutually exclusive in the same PCB. The L option is mutually exclusive with other options in the same PCB.

6. Reserved Area for Data Language/I - Data Language/I uses this area for its own internal linkage related to an application program. This field is one binary word.

7. Segment Name Feedback Area - Data Language/I fills this area with the name of the lowest segment encountered in its attempt to satisfy a call.. When a retrieve is successful., the name of the retrieved segment is placed here. If a retrieve is unsuccessful, the name returned is that of the last segment, along the path to the desired segment, that satisfied the segment search argument.

This field contains eight bytes of character data. This field may be useful in GN and GNP calls.

8. Length of Key Feedback Area - This entry specifies the length of the area required to contain thecomplet'ely qualified key of any sensitive segment. This field is one binary word. The

completely qualified key of a third-level segment includes the first- and second-level keys.

9. Number of Sensitive Segment Types - This entry specifies the number of segment types in the data base to which the application program is sensitive. This field is one binary word.

10. Key Feedback Area - Data Language/I places in this area the

completely qualified key of the lowest segment encountered in its attempt to satisfy a call. When a retrieve is successful, the key of the requested segment and the key field of each segment along the path to the requested segment are concatenated and placed in this 'area. The key fields are positioned from left to

right, beginning with the root segme~t key and following the

(

)

~

/

I I

hierarchical path. When a retrieve is unsuccessful, the keys of

Dans le document Information Management System/360 for the (Page 75-79)