ca repository for z/os - ftpdocs.broadcom.com

78
Copybook Interface Product Guide r7.2 CA Repository for z/OS

Upload: others

Post on 18-Apr-2022

7 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: CA Repository for z/OS - ftpdocs.broadcom.com

Copybook Interface Product Guide r7.2

CA Repository for z/OS

Page 2: CA Repository for z/OS - ftpdocs.broadcom.com

This documentation and any related computer software help programs (hereinafter referred to as the

"Documentation") are for your informational purposes only and are subject to change or withdrawal by CA at any time.

This Documentation may not be copied, transferred, reproduced, disclosed, modified or duplicated, in whole or in part,

without the prior written consent of CA. This Documentation is confidential and proprietary information of CA and may

not be used or disclosed by you except as may be permitted in a separate confidentiality agreement between you and

CA.

Notwithstanding the foregoing, if you are a licensed user of the software product(s) addressed in the Documentation,

you may print a reasonable number of copies of the Documentation for internal use by you and your employees in

connection with that software, provided that all CA copyright notices and legends are affixed to each reproduced copy.

The right to print copies of the Documentation is limited to the period during which the applicable license for such

software remains in full force and effect. Should the license terminate for any reason, it is your responsibility to certify

in writing to CA that all copies and partial copies of the Documentation have been returned to CA or destroyed.

TO THE EXTENT PERMITTED BY APPLICABLE LAW, CA PROVIDES THIS DOCUMENTATION "AS IS" WITHOUT

WARRANTY OF ANY KIND, INCLUDING WITHOUT LIMITATION, ANY IMPLIED WARRANTIES OF MERCHANTABILITY,

FITNESS FOR A PARTICULAR PURPOSE, OR NONINFRINGEMENT. IN NO EVENT WILL CA BE LIABLE TO THE END USER

OR ANY THIRD PARTY FOR ANY LOSS OR DAMAGE, DIRECT OR INDIRECT, FROM THE USE OF THIS DOCUMENTATION,

INCLUDING WITHOUT LIMITATION, LOST PROFITS, LOST INVESTMENT, BUSINESS INTERRUPTION, GOODWILL, OR

LOST DATA, EVEN IF CA IS EXPRESSLY ADVISED IN ADVANCE OF THE POSSIBILITY OF SUCH LOSS OR DAMAGE.

The use of any software product referenced in the Documentation is governed by the applicable license agreement and

is not modified in any way by the terms of this notice.

The manufacturer of this Documentation is CA.

Provided with "Restricted Rights." Use, duplication or disclosure by the United States Government is subject to the

restrictions set forth in FAR Sections 12.212, 52.227-14, and 52.227-19(c)(1) - (2) and DFARS Section

252.227-7014(b)(3), as applicable, or their successors.

Copyright © 2009 CA. All rights reserved. All trademarks, trade names, service marks, and logos referenced herein

belong to their respective companies.

Page 3: CA Repository for z/OS - ftpdocs.broadcom.com

CA Product References

This document references the following CA product:

■ CA Repository for z/OS

Contact CA

Contact Technical Support

For your convenience, CA provides one site where you can access the

information you need for your Home Office, Small Business, and Enterprise CA

products. At http://ca.com/support, you can access the following:

■ Online and telephone contact information for technical assistance and

customer services

■ Information about user communities and forums

■ Product and documentation downloads

■ CA Support policies and guidelines

■ Other helpful resources appropriate for your product

Provide Feedback

If you have comments or questions about CA product documentation, you can

send a message to [email protected].

If you would like to provide feedback about CA product documentation, complete

our short customer survey, which is also available on the CA Support website,

found at http://ca.com/docs.

Page 4: CA Repository for z/OS - ftpdocs.broadcom.com
Page 5: CA Repository for z/OS - ftpdocs.broadcom.com

Contents 5

Contents

Chapter 1: Defining Data Elements 7

Before You Begin ................................................................................ 7

How the Repository Defines Elements ............................................................ 8

Data Element Definitions ......................................................................... 9

Insert an Element Definition..................................................................... 11

Element Aliases: Logical and Physical ............................................................ 12

Chapter 2: Defining Records and Copybooks 13

Record Generation .............................................................................. 13

COBOL Records ............................................................................. 13

PL/I Records ................................................................................ 14 Assembler Records .......................................................................... 14

The Copybook-Segment Model .................................................................. 15

Record Definitions .............................................................................. 15

Elements ................................................................................... 16

Group Elements............................................................................. 17

Records .................................................................................... 18

Fields ...................................................................................... 20

REC MAP Relationships ...................................................................... 21

Functions ................................................................................... 22 Value ....................................................................................... 23

Copybook ...................................................................................... 23

COPY REC/COPY SEG ........................................................................... 24

COPYCOPY ..................................................................................... 25

RS COPYC ...................................................................................... 25

RM COPYC ...................................................................................... 25

Quick Record ................................................................................... 26

The Quick Record Window ................................................................... 28

The Quick Record Window ................................................................... 28 Define a New Record Using Quick Record .................................................... 30

Maintain Existing Record Definitions with Quick Record ....................................... 41

Impact Analysis within Quick Record ......................................................... 41

Workstations and Migration ..................................................................... 42

Chapter 3: Importing Copybooks 43

The Copybook-Segment Model .................................................................. 44

Page 6: CA Repository for z/OS - ftpdocs.broadcom.com

6 Copybook Interface Product Guide

COBOL and PL/I Copybooks ................................................................. 44

Assembler DSECTS/CSECTS ................................................................. 46

C Typedef Struct Declarations ............................................................... 48

IMS Segments .............................................................................. 49

How Copybook Import Populates the Repository ................................................. 50 Basic Elements ............................................................................. 50

Group Elements............................................................................. 51

Records and Segments ...................................................................... 51

Copybooks ................................................................................. 52

Copybook Import ............................................................................... 52

Stripping Prefixes and Suffixes .................................................................. 59

The Prefix-Stripping Process ................................................................. 59

The Prefix-Suffix File ........................................................................ 62

Edit the Prefix-Stripping JCL ................................................................. 63 Import Limitations .............................................................................. 65

Chapter 4: Generating Records and Copybooks 67

Generate Record Layouts ....................................................................... 67

Generate Copybooks ............................................................................ 70

Chapter 5: Reports 73

Enhanced Element Detail Report................................................................. 73

Record Offset Report ............................................................................ 74

Group Elements............................................................................. 75

Index 77

Page 7: CA Repository for z/OS - ftpdocs.broadcom.com

Chapter 1: Defining Data Elements 7

Chapter 1: Defining Data Elements

This chapter describes the use of the ELEMENT entity type and its related

components to define data elements to CA Repository for z/OS.

Data elements are the basic units used in CA Repository for z/OS. CA Repository

for z/OS uses elements as building blocks for defining tables, indexes, records,

and segments, as well other types of metadata. The CA Repository for z/OS

stores elements as entities of the ELEMENT entity type. The CA Repository for

z/OS uses the information contained in these entities for DB2, IMS, Assembler,

COBOL, and PL/I.

This section contains the following topics:

Before You Begin (see page 7)

How the Repository Defines Elements (see page 8)

Data Element Definitions (see page 9)

Insert an Element Definition (see page 11)

Element Aliases: Logical and Physical (see page 12)

Before You Begin

This chapter assumes you are familiar with the basic Repository navigation

commands and procedures described in the CA Repository for z/OS User Guide.

Specifically, you must know how to:

■ Open a Repository dialog

■ Open the Edit window for a particular entity type

■ Insert entities into the Repository

■ Connect entities by inserting relationships and associations

In addition, it would be helpful to know how to use the JUMP and GOTO

commands to move between entity types.

Page 8: CA Repository for z/OS - ftpdocs.broadcom.com

How the Repository Defines Elements

8 Copybook Interface Product Guide

How the Repository Defines Elements

The following figure shows the Repository object types CA Repository for z/OS

uses to store information pertaining to elements. You can access all of the object

types through the CA Repository for z/OS RECORD dialog.

Each object is described in the next table.

Object Description

ALIAS Stores alternate names for Repository elements. Aliases are tied

to the elements they represent through a PHY AL association.

ELEMENT Stores Repository elements. It is the central component of the

element model.

ELEMENTS Groups the members of the SUB ELS set with other definitions,

such as record into a single Repository object.

GROUP Stores Repository groups as defined to the COBOL, PL/I, and

Assembler languages.

LOGIC AL Links two entities of the SUB ELS set (ELEMENT, ALIAS, or

GROUP) that have the same business meaning but dissimilar

names and attributes. Logical alias associations are for

documentation purposes only.

PHY AL Links an ALIAS entity to an ELEMENT or GROUP entity. The DDL

Manager uses these associations to define physical aliases for

elements: the source entity of a PHY AL association type uses all

the attributes of the target element.

A physical alias ties two occurrences with different names but the

Page 9: CA Repository for z/OS - ftpdocs.broadcom.com

Data Element Definitions

Chapter 1: Defining Data Elements 9

Object Description

same attributes, that is, CUST_ID PIC X(9) and CUST_NUM PIC

X(9).

SUB ELS Groups the entity types ELEMENT, ALIAS, and GROUP so that the

entities of all these types can use or be used by entities of any

component referencing the SUB ELS set.

Data Element Definitions

Each Repository element definition has the following attributes:

Attribute Description

Element Name Stores the name of an entity defining an element. The

element name can contain up to 32 characters.

Business Name A descriptive name used to clarify the purpose of the data

element.

Assembler Name The name of the element as referred to in the Assembler

programming environment.

DB2 Column Name

The name for the DB2 column if the element is used as

part of a DB2 table definition.

Description Additional information describing the data element. You

can enter descriptions up to 240 characters.

Blank Y for COBOL option BLANK WHEN ZERO.

Justify Y for COBOL option JUSTIFIED.

Sign Language option SIGN. Y if the numeric data can be

signed.

Sign Position

Indicates:

Leading (L)

Trailing (T)

Leading Separate (S)

Trailing Separate (X) for COBOL SIGN option

Upper Case Only

Y if the element is UPPER CASE.

Leading Zeros Y for COBOL option LEADING ZERO.

Commas

Y for COBOL option COMMAS.

Data Type Defines internal storage of an element or field. Possible

values include:

Page 10: CA Repository for z/OS - ftpdocs.broadcom.com

Data Element Definitions

10 Copybook Interface Product Guide

Attribute Description

ALPHANUM-Alphanumeric

ALPHA-Alphabetic

BIT-Bit data

BITV-Varying length bit data

CHAR-Character

LONGVAR-Long character varying

VARCHAR-Character varying

COMP-COBOL COMPUTATIONAL format

COMP1-COBOL COMPUTATIONAL-1 format

COMP2-COBOL COMPUTATIONAL-2 format

COMP3-COBOL COMPUTATIONAL-3 format

DATE-DB2 date

DECIMAL-Decimal

FLOAT-Floating Point

FULLWORD-Fullword (four bytes binary)

GRAPHIC-Graphic

LONGVARG-Long graphic varying

VARG-Graphic Varying

HALFWORD-HALFWORD (Two bytes binary)

HEX-Hexadecimal

INTEGER-INTEGER (Four bytes binary)

NUMERIC-Numeric character

PACKED-Packed decimal

POINTER-PL/I pointer (Four bytes binary)

SMALLINT-SMALLINT (Two bytes binary)

TIME-DB2 time

TIMESTMP-DB2 Timestamp

Note: This is not a complete list. Data Types are stored in

the Code Tbl 902.

Picture Clause COBOL or PL/I picture clause and usage clause. If Picture

Clause is blank, the DDL Manager will generate a picture

clause and usage clause based on the values stored in the

attributes Data Type, Length, and Decimal.

Other ELEMENT attributes types are provided to support product-specific or

language-specific information. Descriptions of these fields are available through

the CA Repository for z/OS online help.

Page 11: CA Repository for z/OS - ftpdocs.broadcom.com

Insert an Element Definition

Chapter 1: Defining Data Elements 11

To display a description of an ELEMENT attribute type

1. Start CA Repository for z/OS clist, ARZOS.

2. Use view.dialog to open a CA Repository for z/OS dialog that contains the

ELEMENT entity type.

3. Use view.type to open the Edit window for the ELEMENT entity type.

4. Type a question mark (?) in the input field.

5. Select help from the menu bar. CA Repository for z/OS displays a message

describing the attribute.

Insert an Element Definition

Use the following procedure to add a new element to the Repository.

To define an element

1. Open any Repository dialog containing the ELEMENT entity type.

2. Use view.type to access ELEMENT entity type.

CA Repository for z/OS displays the ELEMENT Edit window.

COMMAND ===> SCROLL ===> PAGE SIZE ------------ CURRENT DIALOG: DB2 ENTITY TYPE: ELEMENT ------------- MAX | FILE EDIT VIEW OPTIONS SYSTEM PROFILE NAVIGATE HELP * | LAST ACTION: NOTHING+ 1 OF 1 * | ELEMENT INFORMATION: * | ELEMENT NAME ===> CUST-ACCT-NUM S: V: | | BUSINESS NAME ===> CUSTOMER ACCOUNT NUMBER | | ===> | | ASSEMBLER NAME ===> CUSTACNM | | DB2 COLUMN NAME ===> CUST-ACCT-NUM | | C NAME ===> custnum | | DESCRIPTION: | | SOURCE ===> | | ---------------BRIEF DESCRIPTION------------- | | | A unique identifier for a customer. The | | | | customer number is assigned by the | | | | customer invoicing system. | | | | | | | | | | | | | | | --------------------------------------------- | | DOMAIN INFORMATION: | | DOMAIN KEY ===> ID | ************************************************************ -----------------

3. Complete each of the fields in the ELEMENT Edit window.

4. Use edit.insert to add the element definition to the Repository.

Page 12: CA Repository for z/OS - ftpdocs.broadcom.com

Element Aliases: Logical and Physical

12 Copybook Interface Product Guide

Element Aliases: Logical and Physical

The CA Repository for z/OS recognizes two types of element aliases:

■ Logical

■ Physical

Logical aliases are data elements that have same meaning in terms of business

usage, but that have different names and attributes. CA Repository for z/OS uses

LOGIC AL associations to link element definitions that are logical aliases. Two

elements connected by a LOGIC AL association type are both fully-usable

element definitions that exist in the Repository independent of one another-the

LOGIC AL connection between such elements is for documentation purposes

only.

Physical aliases, by contrast, are elements that have identical attributes and are

used for the same purposes, but that have different names. Unlike logical

aliases, the Repository stores only one ELEMENT entity for any group of physical

aliases. CA Repository for z/OS stores additional names for the element as ALIAS

entities and links them to the element definition through PHY AL associations.

Unlike logical aliases, which are independent element definitions, ALIAS

elements rely on the information stored in the ELEMENT entity to which they are

connected through a PHY AL association.

Physical aliases should be used if you want both the source and target of the PHY

AL to be evaluated for re-use during DB2 Catsync or Copybook import.

Page 13: CA Repository for z/OS - ftpdocs.broadcom.com

Chapter 2: Defining Records and Copybooks 13

Chapter 2: Defining Records and

Copybooks

This chapter describes how CA Repository stores definitions of records and

copybooks.

The CA Repository DDL Manager for DB2 supports the definition and generation

of both COBOL and PL/I record layouts. The syntax that DDL Manager creates for

COBOL records is based on the IBM VS COBOL for OS/VS manual. The syntax for

PL/I records comes from the IBM OS and DOS PL/I Language Reference Manual.

This section contains the following topics:

Record Generation (see page 13)

The Copybook-Segment Model (see page 15)

Record Definitions (see page 15)

Copybook (see page 23)

COPY REC/COPY SEG (see page 24)

COPYCOPY (see page 25)

RS COPYC (see page 25)

RM COPYC (see page 25)

Quick Record (see page 26)

Workstations and Migration (see page 42)

Record Generation

The DDL Manager provides generation of the following COBOL, PL/I, and

Assembler record definitions and their attributes.

COBOL Records

■ Prefixes and/or Suffixes

■ Fully supported picture clause

■ Occurs clauses (Indexed By, Key is, Depending on)

■ Redefines

■ Renames

■ 88 Level support

Page 14: CA Repository for z/OS - ftpdocs.broadcom.com

Record Generation

14 Copybook Interface Product Guide

■ VALUE CLAUSE

■ BLANK WHEN ZERO

■ Justify Right

■ Filler

■ Group Elements

■ Aliases (Element and Group)

■ Level number overrides

■ Include 01 option

■ 49 Level support

■ Nested Copybooks

PL/I Records

■ Prefixes and/or Suffixes

■ Fully-supported picture clause

■ Based pointers

■ Numeric and variable dimensions

■ Refer clause

■ Aliases (element and group)

■ INIT fields (field and element)

■ Element values (similar to COBOL 88s)

■ Filler (similar to COBOL)

■ Group elements

■ Aliases (element and group)

■ Level number overrides

■ Include 01 option

■ Nested Copybooks

Assembler Records

■ Prefixes and/or Suffixes

■ Define Constant

■ Define Storage

■ C sect

Page 15: CA Repository for z/OS - ftpdocs.broadcom.com

The Copybook-Segment Model

Chapter 2: Defining Records and Copybooks 15

■ D sect

■ LT ORG

■ EQA

■ ORG

The Copybook-Segment Model

The CA Repository components that store definitions of elements, group

elements, and records are shown in the following figure. You can access all of

these components through the CA Repository RECORDS dialog. CA Repository

provides full support of COBOL and PL/I records by relating elements and group

elements to a record. Elements and group elements tie to records through the

FIELD and REC MAP relationships. Descriptions of these components and how

they relate are provided in the sections that follow.

The following diagram shows the CA Repository Model for defining records and

copybooks.

Record Definitions

This section describes the following repository object types that CA Repository

uses to define records and copybooks.

Object Type Stores this information

Elements The basic building blocks for records and group elements.

Group Elements Definitions of group elements.

Records Definition of record layouts.

Fields Relates records to subordinate elements and group elements.

Rec Map

Relationships

Relates records directly to subordinate elements and group

elements.

Functions Links record and segment definitions RecSegs or RecMaps to

the ELEMENTS set with information pertaining to functions

such as redefines.

Value The actual literal value associated with a COBOL 88-Level.

Copybooks

Definition of Copybooks

Copy Rec Relates Copybook to the records it contains.

Copy Seg Relates Copybook to the Segments it contains.

Page 16: CA Repository for z/OS - ftpdocs.broadcom.com

Record Definitions

16 Copybook Interface Product Guide

Object Type Stores this information

Copy Copy Relates a Copybook to its nested Copybooks. CopyCopy is

also the target of the RM Copy and RS Copy relationship,

which relates Records and Recmaps to nested Copybooks.

Elements

The element entity type stores the basic building blocks for element definitions.

ELEMENTS and GROUP ELEMENTS tie to records through the FIELD and REC MAP

relationships. RECORDS and SEGMENTS determine Copybook and Segment

layout for IMS, COBOL, and PL/I. How ELEMENT is related using column

determines the structure of RDBMS tables. ELEMENT definitions depend on the

following element attributes:

Attribute Stores this information

Element Name Name attribute of a CA Repository entity defining an

element (32 characters).

Data Type Internal storage type of element or field.

Length Maximum number of significant digits or characters that the

element will occupy.

Note: Not the storage length.

Decimal Number of significant digits after the decimal point to be

included in the length of the data item.

Picture Clause

COBOL, PL/I, or Assembler picture clause and usage clause.

If Picture Clause is blank, the DDL Manager will generate a

picture clause and usage clause based on the values stored

in the attributes Data Type, Length, and Decimal.

Blank Y for COBOL option BLANK WHEN ZERO.

Justify Y for COBOL option JUSTIFIED.

Sign Y for SIGNED Elements.

Sign Position Indicates:

Leading (L)

Trailing (T)

Leading Separate (S)

Trailing Separate (X) for COBOL SIGN option

Upper Case Only Y if the element is UPPER CASE.

Leading Zeros Y for COBOL option LEADING ZERO.

Commas Y for COBOL option COMMAS.

Page 17: CA Repository for z/OS - ftpdocs.broadcom.com

Record Definitions

Chapter 2: Defining Records and Copybooks 17

Attribute Stores this information

Assembler

Operation

The Assembler Operation Code.

When generating records, the DDL Manager uses the Element Name as the field

name. If generating for use with COBOL, the DDL Manager converts any

embedded spaces or underscores found in the name to hyphens. Likewise, when

generating records for PL/I, the DDL Manager converts embedded spaces and

hyphens to underscores.

The ALIAS entity type defines alternate names for elements. A PHY AL

association links an alias element to an element with the same business meaning

and the correct physical characteristics (Data Type, Length, Decimal and Picture

Clause). During DDL generation, the DDL Manager uses the name of the ALIAS

element as the field name and selects all other characteristics from the target of

the PHY AL association.

Group Elements

The GROUP entity type stores definitions of group elements. DDL Manager for

DB2 supports 10 levels of group elements. This means a record or group can

relate to a group element that in turn relates to another group element. This can

repeat for eight more levels. Group elements relate to subordinate entities

through the FIELD relationship (see the Fields section later in this chapter).

The DDL Manager uses information in the following GROUP attributes when

generating group elements:

Attribute Stores this information

Group Name Name of the GROUP entity (32 characters).

Automatic Y for COBOL option AUTOMATIC.

Synchronized Y for COBOL option SYNCHRONIZED.

Aligned ALIGNED (Y) or the UNALIGNED (N) options for PL/I

generation.

Controlled Y for PL/I option CONTROLLED.

Static Y for the PL/I option STATIC.

When generating records or copybooks, the DDL Manager uses the Group

Name attribute as the name of the group field. If generating for COBOL, the DDL

Manager converts embedded spaces or underscores found in the name to

hyphens. For PL/I, it converts embedded spaces and hyphens to underscores.

Page 18: CA Repository for z/OS - ftpdocs.broadcom.com

Record Definitions

18 Copybook Interface Product Guide

You can use the ALIAS entity type to define an alternative name for a group

element. PHY AL associations link alias elements to group elements with the

same business meaning. During DDL generation, the DDL Manager uses the

name of the ALIAS element as the group field name, but selects any subordinate

fields from the target of the PHY AL association.

Records

The RECORD entity type stores definitions of record layouts. Each field in the

record can have a target group element which itself is a part of subordinate field

relationships. Including the initial record level, the DDL Manager supports up to

10 levels of group elements. This means a record or group can be related to a

group element that is in turn related to another group element. This can be

repeated for 8 more levels. The Repository relates records to subordinate

entities through the FIELD and REC MAP relationships.

Records can also be 01 level elements. These are 01 levels that contain their own

element information. There are no subordinate groups or elements with 01 level

elements.

The DDL Manager uses information from the following RECORD attributes when

generating records:

Attribute Stores this information

Record Name Name of the RECORD entity (32 characters).

Prefix Prefix of the record and all of its subordinate fields. The

prefix may contain up to 15 characters and must include a

hyphen if one is desired. The combination of the prefix

and any field in the record definition must not exceed a

maximum length of 32 characters.

Automatic Y for COBOL option AUTOMATIC.

Synchronized Y for COBOL option SYNCHRONIZED.

Aligned

ALIGNED (Y) or the UNALIGNED (N) options for PL/I

generation.

Controlled Y for PL/I option CONTROLLED.

Static Y for the PL/I option STATIC.

External Y for COBOL option EXTERNAL.

Connected Y for PL1 option CONNECTED.

Dimension 1 For COBOL: numeric value of the OCCURS clause.

For PL/I: first of a possible 15 array dimensions.

Page 19: CA Repository for z/OS - ftpdocs.broadcom.com

Record Definitions

Chapter 2: Defining Records and Copybooks 19

Attribute Stores this information

Dimension 2

For COBOL: the upper limit of an OCCURS clause with the

keyword THRU (the lower limit of the OCCURS clause is

the value stored in Dimension 1).

For PL/I: the second array dimension (if non-zero).

Dimension 3 To 15 Dimensions 3 - 15 for PL/I.

Data Type Internal storage type of element or field.

Note: For 01 level elements only.

Length

Maximum number of significant digits or characters that

the element will occupy.

Note: Not the storage length; for 01 level elements only.

Decimal Number of significant digits after the decimal point to be

included in the length of the data item.

Note: For 01 level elements only.

Picture Clause COBOL, PL/I, or Assembler picture clause and usage

clause. If Picture Clause is blank, the DDL Manager will

generate a picture clause and usage clause based on the

values stored in the attributes Data Type, Length, and

Decimal.

Note: For 01 level elements only.

Blank Y for COBOL option BLANK WHEN ZERO.

Note: For 01 level elements only.

Justify

Y for COBOL option JUSTIFIED.

Note: For 01 level elements only.

Sign Y for SIGNED Elements.

Note: For 01 level elements only.

Sign Position

Indicates:

Leading (L)

Trailing (T)

Leading Separate (S)

Trailing Separate (X) for COBOL SIGN option.

Note: For 01 level elements only.

Upper Case Only

Y if the element is UPPER CASE.

Note: For 01 level elements only.

Leading Zeros Y for COBOL option LEADING ZERO.

Note: For 01 level elements only.

Commas Y for COBOL option COMMAS.

Page 20: CA Repository for z/OS - ftpdocs.broadcom.com

Record Definitions

20 Copybook Interface Product Guide

Attribute Stores this information

Note: For 01 level elements only.

During DDL generation, the DDL Manager uses the Record Name as the name

of the record field. If generating for COBOL, the DDL Manager converts

embedded spaces or underscores found in the name to hyphens. For PL/I, it

converts embedded spaces and hyphens to underscores.

To generate a record layout for a selected RECORD entity, use the

options.ddldb2 command to access the DDL Generation window for elements.

Fields

The FIELD relationship type relates records to subordinate elements and group

elements. FIELD relationships also relate group elements to subordinate

elements and other group elements. The FIELD relationship provides a method

of sequencing the fields within a record or a group.

The name of a field is a system-generated concatenation of the names of its

source and target. The source of a FIELD relationship can be any entity in the

GROUPS set (GROUP and RECORD entities). The target of a FIELD relationship

can be any entity in the SUB ELS set (ELEMENT, ALIAS or GROUP entities).

The DDL Manager uses the information from the following FIELD attributes when

generating records and group elements.

Attribute - Stores this information.

Seq Num - Sequence number of field.

During DDL generation, the fields of a record or group are sequenced in

ascending order of this attribute. Fields with the same SEQ NUM are ordered by

Field Name, Status, and Version.

Note: Since there can be many revisions of a field, it is possible to run out of

version numbers. To prevent this, once the maximum number of versions has

been exceeded, the sequence number is appended to the field name already

consisting of a concatenation of source name and target name.

Page 21: CA Repository for z/OS - ftpdocs.broadcom.com

Record Definitions

Chapter 2: Defining Records and Copybooks 21

REC MAP Relationships

The REC MAP relationship type relates records directly to subordinate elements

and group elements. The name of each REC MAP relationship is a

system-generated concatenation of the names of its source and target, and the

sequence number. The source of a REC MAP relationship can be any entity in the

RECSEG set (RECORD and SEGMENT entities). The target of a REC MAP

relationship can be any entity in the SUB ELS set (ELEMENT, ALIAS or GROUP

entities).

The DDL Manager uses the information from the following REC MAP attributes

when generating records and group elements.

Note: REC MAP attributes override any analogous, non-blank attributes of the

target ELEMENT entity as well as those of the FIELD relationship linking ELEMENT

to the RECORD or its parent GROUP.

Attribute Stores this information

Seq Num Sequence number of field. During DDL generation, the fields

of a record or group are sequenced in ascending order of this

attribute. Fields with the same SEQ NUM are ordered by Field

Name, Status, and Version.

Aligned Y if PL/I Aligned.

Dimension 1 Numeric value of OCCURS clause for COBOL.

First of a possible 15 array dimensions for PL/I.

Dimension 2 For COBOL: the upper limit of an OCCURS clause with the

keyword THRU (the lower limit of the OCCURS clause is the

value stored in Dimension 1).

For PL/I: the second array dimension (if non-zero).

Dimension

3 to 15

Dimensions 3 - 15 for PL/I.

VALUE VALUE IS clause for COBOL.

INIT clause for PL/I.

SPACES option for COBOL (parentheses should not be present

in the VALUE attribute).

Note: If the data type of the target element is non-numeric,

the value must be enclosed by parentheses.

Filler Length The length of the element, if used as a filler.

L49 Len Name The 49 level name of the Length field.

L49 Text Name The 49 level name of the Text field.

Page 22: CA Repository for z/OS - ftpdocs.broadcom.com

Record Definitions

22 Copybook Interface Product Guide

Functions

Both the FUNCTION and RM FUNC relationship types are designed to provide

support for special COBOL and PL/I language features, such as REDEFINES,

RENAMES, and INDEX BY. The FUNCTION relationship type links record and

segment definitions (RECSEGS) to the ELEMENTS set, while the RM FUNC

relationship type links REC MAP relationships to ELEMENTS.

During DDL generation, the DDL Manager checks the 01 level entity to see if it is

the source of any FUNCTION relationship. It also checks the subordinate's REC

MAP relationship to see if it is the source of a RM FUNC relationship. The

combination of information in the FUNCTION and RM FUNC relationships are

used to generate any special features.

Note: The target of these functions should not be a field.

The attributes of FUNCTION and RM FUNC are described in the following table.

Attribute Description

Seq Num Sequence number of function. At generation, functions are

sequenced in ascending order of this attribute. Functions with

the same SEQ NUM are ordered by Function Name, Status

and Version.

Function Type The type of function. The available function types and any

restrictions are listed in the following table.

Note: Some functions do not require the FUNCTION or RM FUNC

relationships-they are supported by other entities. The following list contains all

functions supported by the Repository.

Function Description Maximum

per field

Based PL/I-based pointer. 1

Dimension Variable PL/I dimension. 15

Depending DEPENDING ON phrase of COBOL occurs clause.

Requires that an OCCURS also be defined by

specifying a value in the DIMENSION 1 attribute of

the field or the field's source entity.

1

Index By INDEXED BY phrase of COBOL occurs clause.

Requires that an OCCURS also be defined by

specifying a value in the DIMENSION 1 attribute of

12

Page 23: CA Repository for z/OS - ftpdocs.broadcom.com

Copybook

Chapter 2: Defining Records and Copybooks 23

Function Description Maximum

per field

the field or the field's source entity.

Key

KEY IS phrase of COBOL occurs clause. Requires

that an OCCURS be defined by specifying a value in

the DIMENSION 1 attribute of the field or the field's

source entity.

12

Redefine REDEFINES clause for COBOL fields BASEADDR or

DEF Clause for PL/I fields.

1

Rename RENAMES clause for COBOL fields. If two Rename

functions are defined on a field, the keyword THRU

will be used to specify a range.

2

Refer PL/I REFER clause. A BASED function must also

exist to generate a REFER clause.

1

PL/I Like PL/I LIKE CLAUSE. 1

Value

The Value Entity type stores the actual literal value associated with a COBOL

88-Level. COBOL 88-Levels are condition names that are defined for an

elementary data item or record and assigned a value. Testing the condition name

is the same as testing the data item or record for the value. The CA Repository

element type VALUE holds the value associated with the elementary data item or

record. It is related to the elementary data item or record by the RM VALUE

relationship (ELEMENT) or the EL VALUE (record).

Attribute Description

VALUE CLAUSE The value referenced in the COBOL value clause

associated with an 88-Level.

Copybook

The Copybook entity type stores definitions of a copybook. Copybooks are

related to records or segments through the COPY REC or COPY SEG

relationships. Copybooks can also include other copybooks, referred to as

Nested Copybooks.

Attribute Contains this information

Copybook Name Name of the Copybook.

Page 24: CA Repository for z/OS - ftpdocs.broadcom.com

COPY REC/COPY SEG

24 Copybook Interface Product Guide

Attribute Contains this information

Qualified Dataset The name of the data set where the Copybook resides.

Language P for PL1, C for COBOL and A for Assembler.

Import Date

The date the Copybook was last imported.

Include 01 Y if 01 levels are to be generated for every record in the

copybook.

Prefix The prefix to be generated with every field in every record

related to the Copybook.

Suffix The suffix to be generated with every field in every record

related to the Copybook.

Note: Include 01, Prefix, and Suffix override the specification for these fields on

COPY REC relationship and RECORD entity.

COPY REC/COPY SEG

Copybooks are related to records or segments through the COPY REC or COPY

SEG relationships.

Attribute Contains this information

Seq Num Sequence number of the record/segment within a copybook.

During DDL generation the records are sequenced in ascending

order of this attribute. Records with same sequence number are

ordered by Element name, Status, and Version.

Include 01 Y if 01 levels are to be generated for this record.

A value of Y or N in this field overrides the Include 01 value in

the record entity.

Prefix

The prefix to be generated for the record.

Suffix The suffix to be generated for the record.

Prefix 01 Y if the 01 level of this record is to be prefixed.

Suffix 01 Y if the 01 level of this record is to be suffixed.

Page 25: CA Repository for z/OS - ftpdocs.broadcom.com

COPYCOPY

Chapter 2: Defining Records and Copybooks 25

COPYCOPY

The COPYCOPY relationship relates Copybooks to Nested Copybooks. The name

for each COPYCOPY is a system generated concatenation of the names of its

source and target names.

Attribute Contains this information

Seq Num Sequence number of the Nested Copybook.

PRE01 Y if the copy statement is before the 01 level.

Copy Type The Type of Copy statement valid values are:

-INC

% INCLUDE

COPY

++ INCLUDE

RS COPYC

The RS COPYC relationship relates a RECORD or SEGMENT to its Nested

Copybooks.

Attribute Contains this information

Seq Num Sequence number of the Nested Copybook.

RM COPYC

The RM COPYC relationship relates a REC MAP to its Nested Copybooks.

Attribute Contains this information

Seq Num Sequence number of the Nested Copybook.

Page 26: CA Repository for z/OS - ftpdocs.broadcom.com

Quick Record

26 Copybook Interface Product Guide

Quick Record

The CA Repository stores definitions of record layouts using the components of

the Copybook-Segment model. Although this model involves few actual

components, many are, either directly or indirectly, self-referencing, which can

make defining a record seem a bit complicated. The RECORD entity type belongs

to three different entity sets, all of which interconnect through several

relationships and associations (see the figure in The Copybook-Segment Model

section earlier in this chapter).

Although the Copybook-Segment model is accurate showing these

interrelationships, the role of specific entity types is not as apparent. The first

figure on the following page shows the components of the Record model that are

used to define records in a more linear arrangement. These are just the basic

components of a record layout definition: the record itself, its subordinate

elements and group elements.

The second figure contains the same basic record model as the first. In this

figure, however, other components, specifically those used to define 88-level

values and functions for the different elements that make up the record layout,

were added. Though this version of the Record model still uses only eight

different types of objects, you can begin to see how complex a record layout

definition might seem when viewing it one component at-a-time using standard

edit procedures.

Quick Record streamlines the entire record layout definition process. From a

single facility you can insert all of the components required to define a record

layout, including:

■ Subordinate elements

■ Subordinate groups and their respective subordinates

■ Functions for elements

■ 88-level values for subordinate elements

This facility not only reduces the amount of time required to create new record

layout definitions, but aids in maintaining existing definitions as well. When

existing record layout definitions are selected for Quick Record processing, Quick

Record displays all levels of subordinate elements and groups.

Page 27: CA Repository for z/OS - ftpdocs.broadcom.com

Quick Record

Chapter 2: Defining Records and Copybooks 27

The following diagram shows the basic structure of a Repository Record

Definition

The following diagram shows the structure of a record definition displaying its

values and functions.

Page 28: CA Repository for z/OS - ftpdocs.broadcom.com

Quick Record

28 Copybook Interface Product Guide

The Quick Record Window

Before you can access Quick Record, you need to select a record for processing.

The steps required to select a RECORD entity and open the Quick Record window

are listed in the following procedure.

To open the Quick Record window

1. Use view.type to open the Edit window for the RECORD entity type. The

RECORD entity type can be found in most of dialogs included with the CA

Repository.

2. Select (tag) a RECORD entity. If you are creating a new record definition,

INSERT a record entity with desired name, status, and version.

3. Select options.quick.rec from the menu bar. CA Repository displays the

Quick Record window.

COMMAND ===> SCROLL ===> PAGE SIZE --------------------------- QUICK RECORD ---------------------------- MIN | PROCESS DETAIL OPTIONS IMPACT WORKSTN PROFILE NAVIGATE HELP | | | | RECORD INFORMATION: DEFAULT STATUS: DBXT | | RECORD : GENERIC CUSTOMER RECORD, DBXT, 00 | | LANGUAGE : C PREFIX : SUFFIX : | | SYNCHRONIZED: INCLUDE 01: | | | | DESCRIPTION : | | : | | | | SEQ LVL GROUP/ELEMENT NAME STATUS VER OCC 1 | | ---- --- ----------------------------------------- -------- --- ----- | | ___ 1 02 CUSTOMER-NAME DBXT 00 0 | | ___ 2 03 CUSTOMER-LAST-NAME DBXT 00 0 | | ___ 3 03 CUSTOMER-FIRST-NAME DBXT 00 0 | | ___ 4 03 CUSTOMER-MIDDLE-NAME DBXT 00 0 | | ___ 5 02 CUSTOMER-NUMBER DBXT 00 0 | | | | | | | | | **************************************************************** ------------

The Quick Record Window

The top section of the record window contains information about the record you

selected for processing. The Name, Status, and Version of the RECORD are

protected, so if you need to change any of this information, you have to do it

from the RECORD Edit window.

Page 29: CA Repository for z/OS - ftpdocs.broadcom.com

Quick Record

Chapter 2: Defining Records and Copybooks 29

The bottom section of the Quick Record window lists any elements and group

elements that are already defined as part of the record layout. In the CA

Repository these are ELEMENT and GROUP entities that are linked to the selected

RECORD entity through FIELD and REC MAP relationships. If the record you

selected was one that you inserted just before processing, no such connections

exist and these fields are blank.

The Element fields in the Quick Record window are:

Field Contains

SEQ The sequence number of the data element within the record.

When rows are added or deleted during the course of

processing, CA Repository will automatically update these

numbers.

LVL The level number of the element within the record.

Group/

Element Name

Repository identifier for the ELEMENT or GROUP entities linked

to the RECORD entity.

Status Status for the ELEMENT or GROUP.

Version

Version number for the ELEMENT or GROUP.

OCC1 Value of the OCCURS clause for the element or group element.

OCC2 The upper limit of an OCCURS clause with the keyword THRU.

FNC Y indicates that a function is tied to the group or element.

N indicates that the group or element is not linked to a

function.

VAL Y indicates that an 88-level value is tied to the group or

element.

N indicates that the group or element is not linked to a value.

Quick Record supports from two to ten levels of subordinate elements. All levels

must be consecutive (the record itself is level 01). Quick Record automatically

indents rows according to their level numbers in order to make group elements

and their respective subordinates more obvious on the display.

Page 30: CA Repository for z/OS - ftpdocs.broadcom.com

Quick Record

30 Copybook Interface Product Guide

Define a New Record Using Quick Record

Creating a record layout definition from scratch consists of the following basic

steps. Each is explained in detail on the following pages.

Step Procedure

1 Inserting a RECORD entity

2 Linking the Record to Elements

3 Adding Detail Data to Elements

4

Defining Group Elements

5 Defining Functions

6 Processing the Record Definition

7 Defining 88-level Values

Step 1. Insert a RECORD Entity

Before you can access Quick Record, you need to select (tag) a RECORD entity.

If you are creating a new record, you need to insert a RECORD entity first.

1. Open the Edit window for the RECORD entity type.

2. Insert a RECORD entity. See the CA Repository for z/OS User Guide for

instructions on inserting entities into the Repository.

Page 31: CA Repository for z/OS - ftpdocs.broadcom.com

Quick Record

Chapter 2: Defining Records and Copybooks 31

3. Use options.quick.rec to open the Quick Record window.

When defining a new record, the fields of the Quick Record window are

empty as no connections between the new RECORD entity and data

elements have been established. The following is an empty Quick Record

window.

COMMAND ===> SCROLL ===> PAGE SIZE --------------------------- QUICK RECORD ---------------------------- MIN | PROCESS DETAIL OPTIONS IMPACT WORKSTN PROFILE NAVIGATE HELP | | | | RECORD INFORMATION: DEFAULT STATUS: DBXT | | RECORD : GENERIC CUSTOMER RECORD, DBXT, 00 | | LANGUAGE : C PREFIX : SUFFIX : | | SYNCHRONIZED: INCLUDE 01: | | | | DESCRIPTION : | | : | | | | SEQ LVL GROUP/ELEMENT NAME STATUS VER OCC 1 | | ---- --- ----------------------------------------- -------- --- ----- | | ___ 1 02 DBXT 00 0 | | | | | **************************************************************** -------------

Step 2. Link the Record to Elements

Once you select a RECORD entity and open the Quick Record window, you need

to link the record to one or more data elements.

To link the Record to a data element

1. Enter the attributes into the Group/Element input fields, that is, Name,

Status, Version, Description, and so on.

You can also enter a question mark in the GROUP/ELEMENT NAME field to

access a selection list of data element definitions that already exist in the

Repository.

Page 32: CA Repository for z/OS - ftpdocs.broadcom.com

Quick Record

32 Copybook Interface Product Guide

2. If desired, add more element rows using line commands (i, r, and so on).

COMMAND ===> SCROLL ===> PAGE SIZE --------------------------- QUICK RECORD ---------------------------- MIN | PROCESS DETAIL OPTIONS IMPACT WORKSTN PROFILE NAVIGATE HELP | | | | RECORD INFORMATION: DEFAULT STATUS: DBXT | | RECORD : GENERIC CUSTOMER RECORD, DBXT, 00 | | LANGUAGE : C PREFIX : SUFFIX : | | SYNCHRONIZED: INCLUDE 01: | | | | DESCRIPTION : | | : | | | | SEQ LVL GROUP/ELEMENT NAME STATUS VER OCC 1 | | ---- --- ----------------------------------------- -------- --- ----- | | ___ 1 02 CUSTOMER-NAME DBXT 00 0 | | ___ 2 02 CUSTOMER-NUMBER DBXT 00 0 | | | | | | | | | | | | | | | **************************************************************** -------------

Step 3. Add Detail Information to Elements

If you are not using an existing element definition, you must add additional

information using the Detail window or CA Repository will be unable to insert an

ELEMENT entity when the record layout is processed.

When using an existing element definition, you do not have to change detail

information to suit your particular needs since during the processing phase of

Quick Record definition, CA Repository checks to see if the altered element

definition is used by other entities before it is actually updated and inserts a new

version of the element if it is. Quick Record only updates an existing ELEMENT

entity if it is not used by other relationships or associations.

To add detail information to an element

1. Tag one or more element rows.

Page 33: CA Repository for z/OS - ftpdocs.broadcom.com

Quick Record

Chapter 2: Defining Records and Copybooks 33

2. Select detail.viewedit from the Quick Record menu. CA Repository displays

the Element ViewEdit window.

COMMAND ===> SCROLL ===> PAGE SIZE ------------------------- ELEMENT VIEWEDIT -------------------------- MIN | DETAIL PROFILE NAVIGATE HELP * | * | ELEMENT NAME: CUSTOMER-NAME * | STATUS: DBXT VERSION: 00 * | * | DB2 COLUMN NAME => * | ASSEMBLER NAME => * | DATA TYPE => CHAR * | MAXIMUM LENGTH => 25 * | DECIMAL PLACES => 0 * | PICTURE CLAUSE => * | * | BLANK WHEN ZERO => (Y/N) LEADING ZEROS => (Y/N) * | SIGNED => (Y/N) SIGN POSITION => (L/T) * | RIGHT JUSTIFY => (Y/N) COMMAS => (Y/N) * | UPPER CASE ONLY => (Y/N) * | * | INITIAL VALUE => * | => * | * | DESCRIPTION => * -----------------------------------------------------------------------------|

3. Complete each of the fields as desired (for descriptions of the Element and

GROUP fields, see the Elements section and the Group Elements section,

respectively, earlier in this chapter).

Note: Initial Value is stored on the REC MAP relationship between the Record

and this Element.

4. Press PF3 to exit the Element ViewEdit window.

If you selected multiple Elements prior to opening the ViewEdit window,

pressing PF3 displays the next element in the ViewEdit window. When you

close the last ViewEdit window, CA Repository displays the Quick Record

window.

Page 34: CA Repository for z/OS - ftpdocs.broadcom.com

Quick Record

34 Copybook Interface Product Guide

Step 4. Define Group Elements

If necessary, you can create group elements from the Quick Record. This is

simply a matter of adding additional rows to the Quick Record window and

adjusting the level numbers to reflect the group-element hierarchy.

To define a group element in the Quick Record window

1. Use a line command in the select byte to add the necessary number of rows

(i = insert, r = repeat, and so on). You will need to place rows referring to

subordinate elements directly beneath their superior group.

2. Add or change the information in the Group/Element Name, Status, and

Ver fields to define the new subordinate elements.

Typing a question mark in the name field produces a selection list of existing

elements. If you select a group element from this list, CA Repository

retrieves all of its subordinate elements (and groups) to the Quick Record

window.

3. Change the level number of the new subordinate elements to “1 + the level

number of the group element.” Pressing enter anytime after a level number

is changed allows CA Repository to make the necessary indentations.

4. Tag each of the new rows and use the detail.viewedit command to change

the element detail data as necessary. The following screen shows a record

containing a group element

COMMAND ===> SCROLL ===> PAGE SIZE --------------------------- QUICK RECORD ---------------------------- MIN | PROCESS DETAIL OPTIONS IMPACT WORKSTN PROFILE NAVIGATE HELP | | | | RECORD INFORMATION: DEFAULT STATUS: DBXT | | RECORD : GENERIC CUSTOMER RECORD, DBXT, 00 | | LANGUAGE : C PREFIX : SUFFIX : | | SYNCHRONIZED: INCLUDE 01: | | | | DESCRIPTION : | | : | | | | SEQ LVL GROUP/ELEMENT NAME STATUS VER OCC 1 | | ---- --- ----------------------------------------- -------- --- ----- | | ___ 1 02 CUSTOMER-NAME DBXT 00 0 | | ___ 2 03 CUSTOMER-LAST-NAME DBXT 00 0 | | ___ 3 03 CUSTOMER-FIRST-NAME DBXT 00 0 | | ___ 4 03 CUSTOMER-MIDDLE-NAME DBXT 00 0 | | ___ 5 02 CUSTOMER-NUMBER DBXT 00 0 | | | | | | | | | **************************************************************** -------------

Page 35: CA Repository for z/OS - ftpdocs.broadcom.com

Quick Record

Chapter 2: Defining Records and Copybooks 35

In the previous example, all of these steps were performed to change the first

element into a group element. First, the line command i3 was used to add three

new rows directly beneath the CUSTOMER-NAME element. New elements names

were then added to each of the new rows. Next, the level of number of each of

the new rows was changed from 02 to 03 to show that these elements were to

subordinate to CUSTOMER-NAME. Finally, detail information was added to each

of the new elements by using the detail.viewedit command for each.

Quick Record assumes that changes made to a group element or any of its

subordinates are only intended for the selected record. This is why a new version

of the group/element is inserted if CA Repository detects that it is used

elsewhere.

Step 5. Define Functions

Quick Record supports the following element functions:

■ DEPENDING ON phrase of an OCCURS clause

■ INDEXED BY phrase of an OCCURS clause

■ ASCENDING KEY IS phrase of an OCCURS INDEXED BY clause

■ DESCENDING KEY IS phrase of an OCCURS INDEXED BY clause

■ REDEFINE clause for COBOL fields

■ RENAME clause for COBOL fields

These functions are stored in the CA Repository as RM FUNC relationships linking

the ties between the record and its subordinates to other elements.

To add a function to a record layout definition

1. Tag the element (row) for which the function is being defined.

2. Select detail.function from the Quick Record menu.

Note: You can also access the Function window by selecting the

detail.function option from an element's Detail window.

3. Select the function you want to attach to the element from the resulting

function menu.

Option Selects this function

DEPEND Depending On

DESC KEY Descending Key Is

INDEX BY Indexed By

KEY Ascending Key Is

REDEFINE Redefines

Page 36: CA Repository for z/OS - ftpdocs.broadcom.com

Quick Record

36 Copybook Interface Product Guide

Option Selects this function

RENAME Renames

At this point CA Repository prompts you for a target element for the function.

Type the name, status, and version of the element into the appropriate input

fields or enter a question mark in the name field to generate a list of element

definitions that are already in the Repository.

CA Repository displays a Define Function window for the link between the

record and the selected element. The following window is a Quick Record

window for a REDEFINES clause.

SIZE --------------------------- QUICK RECORD ---------------------------- MIN | PROCESS DETAIL OPTIONS IMPACT WORKSTN PROFILE NAVIGATE HELP | | | VIEWEDIT | | | RECORD | LEVEL-88 | DEFAULT STATUS: DBXT | | RECOR | FUNCTION > | CUSTOMER RECORD, DBXT, 00 | | LA SIZE --------------------- DEFINE FUNCTION --------------------- MAX | | SY | CANCEL PROFILE NAVIGATE HELP | | | | | | | DE | FUNCTION FOR : CUSTOMER-SOCIAL-SECURITY-NUMBER, DBXT, 00 | | | | | | | | FUNCTION TYPE : REDEFINE | | | | | | | | TARGET NAME : | | | ___ | TARGET STATUS : DBXT TARGET VERSION: 00 | | | ___ | | | | ___ | SEQUENCE NUMBER: 1 OF 1 | | | ___ | | | | ___ ************************************************************** ----- | | _S_ 6 02 CUSTOMER-SOCIAL-SECURITY-NUMBER DBXT 00 0 | | | | | **************************************************************** -------------

4. Press pf3 to close the Function window and add the function to the selected

element.

Once you define a function for an element or group, a Y appears in the FNC

column for that element. You may have to scroll the window to the right to

see it.

5. To exit the Function window without adding a function:

Select the CANCEL option from the action bar.

Exiting from the window with END or PF3 applies changes, so they should not

be used to back out of the Define Function window.

Page 37: CA Repository for z/OS - ftpdocs.broadcom.com

Quick Record

Chapter 2: Defining Records and Copybooks 37

Step 6. Process the Record Definition

Once you have entered all the elements, group elements, and functions for your

record you can use the Quick Record PROCESS command to start the Quick

Record process. When you start processing, Quick Record performs the following

tasks:

■ Compares all elements and groups in the Quick Record window with those

already in the Repository.

■ Inserts new entities for those elements and groups that have no existing

counterparts in the Repository.

■ Inserts new versions of entities for those elements and groups that have

different detail information or different subordinates than their existing

counterparts. CA Repository updates existing entities (rather than insert

new versions) if it detects that they are not used elsewhere.

■ Inserts FIELD and REC MAP relationships to link the record layout to its

subordinate groups and elements. Quick Record inserts additional FIELD

relationships to link all groups to their respective subordinates.

■ Inserts RM FUNC relationships to link connections between the record and its

subordinates to the appropriate ELEMENT/GROUP entities.

■ In certain instances, Quick Record also performs name generation

processing. If blank, Quick Record will generate the DB2_COLUMN_NAME

attribute for elements and the ASSEMBLER_NAME attribute for elements and

groups.

When Quick Record completes processing, the Quick Record window reappears.

If new versions of elements were created, the changes will be reflected in the

window. The END command (PF3) can be used to close the Quick Record window

and return to the RECORD Edit window.

How ARZOS Compares Elements During Quick Record Processing

Each time you process a record layout definition using Quick Record, CA

Repository compares the elements and groups specified in the Quick Record

window to those that exist in the Repository. If it finds an element in the

Repository that matches the name, status, and version of an element in the

Quick Record window, CA Repository will compare the two definitions to see if, in

fact, they define the same element.

The attributes CA Repository uses to make this comparison are: Data Type,

Length, Decimal, Picture Clause, Value, Sign, Sign Position, Leading Zeros,

Commas, Blank When Zero, Justify, and Uppercase.

Page 38: CA Repository for z/OS - ftpdocs.broadcom.com

Quick Record

38 Copybook Interface Product Guide

If the element in the Quick Record window and the like-named element in the

Repository have different values for any of these attributes, CA Repository

updates the element only if it is not a subordinate of any other record, segment,

or group. Otherwise, it inserts a new version of element for use with the record

layout being processed with Quick Record.

CA Repository also uses the attributes DB2 COLUMN NAME and ASSEMBLER

NAME for comparing two elements. Unlike the attributes listed previously, these

attributes do not cause the elements to be marked as different if unspecified

(blank) in either the Repository or Quick Record version. In instances where one

version has a blank attribute and the other does not, CA Repository uses the

non-blank value for the Repository version of the element and uses that element

for the record layout definition.

REFRESH Command

The REFRESH command allows you to undo changes you made to data in the

Quick Record window. When executed, all data in the window reverts back to the

state it was in when you entered the Quick Record window or last executed the

PROCESS command (whichever was most recent).

Step 7. Define 88-level Values

Once you have processed the record layout, you can define 88-level values for its

constituent groups and elements.

To define 88-level values for groups and elements

1. Tag the element (row) for which the 88-level value is to apply.

Page 39: CA Repository for z/OS - ftpdocs.broadcom.com

Quick Record

Chapter 2: Defining Records and Copybooks 39

2. Select DETAIL.LEVEL-88 from the Quick Record menu. CA Repository

displays the Quick 88 window.

COMMAND ===> SCROLL ===> PAGE

SIZE --------------------------- QUICK RECORD ---------------------------- MIN | PROCESS DETAIL OPTIONS IMPACT WORKSTN PROFILE NAVIGATE HELP | | | VIEWEDIT | | | RECORD | FUNCTION > | DEFAULT STATUS: DBXT | | RECOR | LEVEL-88 > | -CUSTOMER-RECORD, DBXT, 00 | SIZE ----------------------------- QUICK 88 ------------------------------ MAX | PROCESS PROFILE NAVIGATE HELP * | * | REC MAP NAME: GENERIC-CUSTOMER-RECORD.CUSTOMER STS: DBXT VER: 00 * | * | VALUE NAME STATUS VER VALUE * | -------------------------------- -------- --- --------------------------- * | SAMPLE-VALUE-1 DBXT 00 'XXX' * | SAMPLE-VALUE-2 DBXT 00 'M', 'MIDDLE' * | SAMPLE-VALUE-3 DBXT 00 'VALUE' * | DBXT 00 * | DBXT 00 | | DBXT 00 | | DBXT 00 | | DBXT 00 | | DBXT 00 | | DBXT 00 | ******************* ----------------------------------------------------------

The name of the selected element appears in the top portion of the window.

The lower portion of the window lists the VALUE entities (if any) that are

already linked to the selected element. Beneath these are the blank lines for

specifying new values. The Quick 88 window always provides 20 blank lines

for new values. To assign new 88 values to an element, add the appropriate

information to any of the blank lines of the Quick 88 window.

3. Enter a question mark in VALUE NAME to link the element to an existing

value definition. CA Repository displays a list of existing VALUE entities from

which you can select the desired entity.

4. Type the appropriate information into the VALUE input fields to create a new

value definition. You can scroll Quick 88 window to the left or right to reveal

all the VALUE input fields.

5. Select process from the Quick 88 menu. CA Repository creates links

between selected element's REC MAP relationship and the VALUE entities,

inserting new VALUE entities as necessary.

6. Press pf3 when you have completed 88-level processing to close the Quick

88 window and return control the Quick Record window. The element's VAL

flag is set to Y after you have run the Quick 88 process.

Page 40: CA Repository for z/OS - ftpdocs.broadcom.com

Quick Record

40 Copybook Interface Product Guide

Understanding the Quick 88 Process

In instances where you type the value information into the Quick 88 window, CA

Repository checks the Repository to ensure that a VALUE entity with the same

name, status, and version does not already exist in the Repository. If it cannot

find the specified entity, CA Repository will insert a VALUE entity with the

appropriate attributes and link it to the selected element's REC MAP relationship

with a new RM VALUE association.

If a like-named VALUE entity does exist, CA Repository checks to see if it is used

by any other entities. If it is not, CA Repository updates the existing definition to

match the attributes specified in the Quick 88 window.

If the existing VALUE entity is used by other entities, CA Repository inserts (and

links the selected element to) a new VALUE entity using the attributes specified

in the Quick 88 window. CA Repository uses the next available version number

for the new VALUE entity to distinguish it from the existing VALUE entity. This

change is reflected in the Quick 88 window once processing is completed.

Breaking Existing ties to Values

You can also use Quick 88 to break links between elements/fields and values.

Each time you select an element or field for processing, the Quick 88 window lists

any VALUE entities that are currently linked to the selected element or field. To

sever the link to a particular value:

1. Blank out the NAME field for that value.

2. Select PROCESS.

CA Repository deletes the appropriate tie to the value.

Processing Multiple Elements or Fields

Quick 88 will only process one element or field at a time. If you tag multiple

entities prior to processing, CA Repository will process each of the selected

entities in turn.

Note: Make sure you run the PROCESS command from the Quick 88 window.

Quick 88 is a separate facility called from Quick Record-if you do not run the

Quick 88 process, none of the work you perform at this window will be

committed.

Page 41: CA Repository for z/OS - ftpdocs.broadcom.com

Quick Record

Chapter 2: Defining Records and Copybooks 41

Maintain Existing Record Definitions with Quick Record

When you select an existing record definition for Quick Record processing, the

fields of the Quick record window contain all the elements and group elements

that make up that record. You can make changes to the definition by adding,

moving, or deleting rows; by changing detail information; or by adding or

removing functions and 88-level values. When you process the record, CA

Repository updates or insert entities as needed.

Note: The integrity of the SEQ fields in the REC MAP relationship is not

guaranteed during Quick Record processing. You can restore the sequential

integrity in the REC MAP by executing the following commands:

EDIT.CHGSCR.RESEQ

EDIT.SYNC

Note: In the case of replacing existing elements, there are limitations on the

Text5 table values associated with elements having their version number or

status value modified by the Quick Record facility. In order for existing Text5

table values to be preserved through Quick Record processing, the following

condition must be satisfied:

The element name of the placing element must be the same as the element

name for the element that is being replaced.

However, the Text5 table value is not preserved, even when the previous

condition is satisfied, if either of the following conditions is also true:

■ Two or more of the element names being replaced are identical

■ Two or more of the replacing element names are identical

To preserve the Text5 table values when either of the previous two conditions is

true, each individual change must be processed through the Quick Record facility

as a separate and distinct transaction.

Impact Analysis within Quick Record

The Quick Record menu provides access to the standard CA Repository impact

analysis commands XREF, USES, and WHERE using the IMPACT option. These

commands can help you to understand how each of the records components is

related to one another within the CA Repository, and to view those components

(if any) that are related to the record's constituent groups and elements but that

are not part of the record layout definition itself.

Page 42: CA Repository for z/OS - ftpdocs.broadcom.com

Workstations and Migration

42 Copybook Interface Product Guide

Workstations and Migration

Because record layouts can contain many levels of groups and elements, each of

which maps to a different relationship in the CA Repository, moving an entire

record layout definition from one status to another could be a formidable task.

Though placing all of the occurrences used for the record layout in a workstation

would simplify the migration process, the population of the workstation itself

could be somewhat complicated. For this reason all of the workstation

commands are included in the Quick Record window.

When used in conjunction with the TAG command, the Quick Record workstation

commands ADD and ADDONLY can add every entity that is part of a record

layout definition to a workstation, regardless of the number of levels in the

record layout. However, each of these commands has its respective advantages

and disadvantages.

The primary advantage of the ADD command is that it will also include the FIELD

and RECMAP relationships that tie the record to its subordinate groups and

elements. The disadvantage of this command is that it can also add GROUP

entities that are not part of the selected record layout (if the record definition

uses any element definitions that are also used by other groups or records).

While this is not a problem with the ADDONLY command, ADDONLY command

will not include the REC MAP and FIELD relationships.

The workstation DELETE and DELONLY are also available to remove selected

record layout components from a workstation.

Page 43: CA Repository for z/OS - ftpdocs.broadcom.com

Chapter 3: Importing Copybooks 43

Chapter 3: Importing Copybooks

The Copybook Import facility enables you to import Assembler DSECTs, COBOL

and PL/I copybooks, C typedef struct declarations, and IMS segments into the

Repository. This facility helps your organization protect its investment in

Assembler, COBOL, C and PL/I code by providing automated population of the

Repository.

This section contains the following topics:

The Copybook-Segment Model (see page 44)

How Copybook Import Populates the Repository (see page 50)

Copybook Import (see page 52)

Stripping Prefixes and Suffixes (see page 59)

Import Limitations (see page 65)

Page 44: CA Repository for z/OS - ftpdocs.broadcom.com

The Copybook-Segment Model

44 Copybook Interface Product Guide

The Copybook-Segment Model

The CA Repository for z/OS Copybook-Segment model (shown in the following

illustration) contains objects for storing metadata captured during a scan of IMS

segments, Assembler DSECTS, C header files, or COBOL and PL/I copybooks.

This section discusses the roles of these objects as they support these different

types of structures.

COBOL and PL/I Copybooks

The objects of the Copybook-Segment that store definitions of COBOL and PL/I

copybooks are described in the following table.

Object Stores: Which are:

COPYBOOK Copybooks Groupings of record (01 level) definitions. CA Repository for z/OS

uses the name of the partitioned data set member that holds the

copybook as the name of the COPYBOOK entity. For sequential

Page 45: CA Repository for z/OS - ftpdocs.broadcom.com

The Copybook-Segment Model

Chapter 3: Importing Copybooks 45

Object Stores: Which are:

data sets, CA Repository for z/OS names the COPYBOOK

occurrence after the character string found to the right of the last

delimiter in the data set name. CA Repository for z/OS links

COPYBOOK entities to the constituent 01 level through the COPY

REC relationships.

RECORDS Records -

“01” levels

01 levels of a copybook structure. Every copybook structure

defined in the Repository has an occurrence in the RECORD entity

type-although 01 level is not always necessary within an actual

copybook structure (some sites never use 01 level), the Repository

requires a definition of such an object as part of a copybook

definition.

If CA Repository for z/OS does not find an 01 level during an

import, it still inserts a RECORD entity using a default name. When

subsequently generating such a copybook from its Repository

definition, CA Repository for z/OS allows you to specify whether

you want to include the 01 level with the rest of the copybook.

GROUP

Group elements

Groupings of basic elements and other group elements. A group

element does not necessarily have physical characteristics, but

contains or is superior to other objects. A group element usually

has no data type, and its length is the sum of its component

objects.

ELEMENT Basic elements Objects within a copybook that have physical characteristics, such

as Data type and Length, but no subordinate structures (other

than “88” levels in COBOL).

ALIAS Physical aliases Alternative names for basic or group elements. PHY AL

associations link ALIAS entities to the ELEMENT entities they

represent.

LOGIC AL Logical aliases Objects that have different names or physical characteristics, but

serve the same business purpose. Because there is no concept

corresponding to logical aliases within copybook structures, the

Copybook Import facility will never insert a new LOGIC AL

occurrence.

VALUE 88-level values Declarations of the valid values for an element or a physical alias.

FUNCTION Copybook

functions

Clauses used within copybook structures that link one object to

another in a special manner. Valid types of functions include:

Ascending Key

Depending On

Descending Key

Index By

LTORG

Redefines

Page 46: CA Repository for z/OS - ftpdocs.broadcom.com

The Copybook-Segment Model

46 Copybook Interface Product Guide

Object Stores: Which are:

Rename

Connect Records, Group Elements, and Basic Elements

CA Repository for z/OS uses the FIELD and REC MAP relationships to connect 01

level definitions (RECORD) entity type to:

■ Group elements (GROUP)

■ Basic elements (ELEMENT)

■ Physical aliases (ALIAS)

FIELD relationships also connect group elements (GROUP) to:

■ Other group elements

■ Basic elements (ELEMENT)

■ Physical aliases (ALIAS)

Assembler DSECTS/CSECTS

The Copybook-Segment model also stores definitions of Assembler DSECTs and

CSECTs as described in the following table. This model does not support

Assembler macros.

Object Stores: Which are:

COPYBOOK Copybooks Groupings of DSECTs. CA Repository for z/OS

uses the name of the partitioned data set

member that holds the copybook as the name of

the COPYBOOK entity. For sequential data sets,

CA Repository for z/OS names the COPYBOOK

Page 47: CA Repository for z/OS - ftpdocs.broadcom.com

The Copybook-Segment Model

Chapter 3: Importing Copybooks 47

Object Stores: Which are:

occurrence after the character string found to

the right of the last delimiter in the data set

name. CA Repository for z/OS connects

copybook definitions to the DSECT definitions

through the COPY REC relationships.

RECORD DSECT names Names associated with Assembler DSECTs. CA

Repository for z/OS inserts a RECORD for every

DSECT defined to the Repository. If CA

Repository for z/OS does not find a DSECT name

during the scan, it provides a default name.

GROUP

Group

elements

DS and DC fields with duplication factors of 0.

ELEMENT Basic

elements

DS and DC fields with duplication factors greater

than 0 and EQU clauses.

ALIAS Physical

aliases

Alternative names for basic or group elements

within the Repository's Assembler DSECT

definitions.

FUNCTION LTORGs and

ORGs

LTORG and ORG clauses of DSECTs.

Connect DSECT Names to Groups and Basic Elements

CA Repository for z/OS uses FIELD and REC MAP relationships to connect

Assembler DSECT definitions (RECORD) to:

■ Group elements (GROUP)

■ Basic elements (ELEMENT)

■ Physical aliases (ALIAS)

FIELD relationships also connect group elements (GROUP) to:

■ Other group elements

■ Basic elements (ELEMENT)

■ Physical aliases (ALIAS)

Page 48: CA Repository for z/OS - ftpdocs.broadcom.com

The Copybook-Segment Model

48 Copybook Interface Product Guide

C Typedef Struct Declarations

The same model that supports COBOL and PL/I copybooks also describes C

typedef struct declarations. Some minor differences relating to what the

component meta-entities represent are discussed in the following table.

Object: Stores: Which are:

COPYBOOK Copybooks Header files containing groups of typedef

structs. CA Repository for z/OS names the

copybook after the name of the partitioned data

set member or h file that holds the copybook. If

the data set is sequential, the COPYBOOK entity

will be named after the character string found to

the right of the last delimiter in the data set

name. COPYBOOK entities are connected to the

component typedef struct definitions through

the COPY REC relationship type.

RECORD C typedef struct

declarations

Names associated with C typedef struct

declarations. CA Repository for z/OS inserts a

RECORD for every C typedef struct defined to

the Repository. If CA Repository for z/OS does

not find a name during the scan, it provides a

default name.

GROUP

Group elements

Structures within a typedef struct and UNIONs.

ELEMENT Basic elements Variables defined within the typedef structure.

ALIAS Tagged and

declared names

Tagged and declared names for basic, group, or

record elements within C typedef struct

definitions. Aliases are tied to the basic, group,

or record elements through the FUNCTION

entity type.

Connect Record Elements, Group Elements, and Basic Elements

CA Repository for z/OS uses FIELD and REC MAP relationships to connect C

typedef struct definitions to:

■ Group elements (GROUP)

■ Basic elements (ELEMENT)

■ Physical aliases (ALIAS)

Page 49: CA Repository for z/OS - ftpdocs.broadcom.com

The Copybook-Segment Model

Chapter 3: Importing Copybooks 49

FIELD relationships also connect group elements (GROUP) to:

■ Other group elements

■ Basic elements (ELEMENT)

■ Physical aliases (ALIAS)

IMS Segments

Because of the similarity between IMS segment definitions and copybook

structures, very few changes are needed to modify both the Copybook Model and

the Copybook Import Facility to handle IMS segments.

Object: Stores: Which are:

COPYBOOK Copybooks Groups of segment or 01 level definitions. CA

Repository for z/OS connects copybook

definitions to their constituent 01 level with

COPY SEG relationships.

SEGMENT Segments -

01 levels

IMS Segment 01-levels.

GROUP Group elements Elements comprised of two or more

subordinate elements.

ELEMENT

Basic elements

Objects within a segment that have physical

characteristics.

ALIAS Physical aliases Alternative names for basic or group elements

within the Repository's IMS segment

definitions.

VALUE 88-level values 88-level values for segments.

FUNCTION Copybook

functions

The definitions of these connections as they

pertain to segment definitions are still stored

within the FUNCTION relationship type.

Connect Segments, Group Elements, and Basic Elements

CA Repository for z/OS uses IMS FIELD and REC MAP relationships to connect

segment definitions to:

■ Group elements (GROUP)

■ Basic elements (ELEMENT)

■ Physical aliases (ALIAS)

Page 50: CA Repository for z/OS - ftpdocs.broadcom.com

How Copybook Import Populates the Repository

50 Copybook Interface Product Guide

FIELD relationships also connect group elements (GROUP) to:

■ Other group elements

■ Basic elements (ELEMENT)

■ Physical aliases (ALIAS)

How Copybook Import Populates the Repository

As part of the import process, Copybook Import evaluates existing Repository

entities to see if it can re-use instances for the definition of the copybook it is

processing. This section describes how the Import process determines that an

object in the imported copybook matches and existing Repository entity.

Basic Elements

When Copybook Import encounters a basic element in a copybook, it performs

these steps:

1. Compares the significant attributes of the element it needs to insert with

those elements in the Repository. Significant attributes for elements are:

■ Element Name

■ Status

■ Data type

■ Length

■ Decimal

■ Picture Clause

■ Sign

■ Sign Position

■ Leading Zeros

■ Commas

■ Blank when Zero

Page 51: CA Repository for z/OS - ftpdocs.broadcom.com

How Copybook Import Populates the Repository

Chapter 3: Importing Copybooks 51

■ Justify

■ Uppercase

2. If the significant attributes of an element found in a copybook are identical to

an occurrence already in the ELEMENT entity type, it re-uses the existing

element definition, inserting only new relationships and associations to link

the element definition to the copybook definition. It does not duplicate the

ELEMENT entity.

3. If the Copybook Import process cannot find a matching ELEMENT

occurrence, it compares the element in the copybook to ALIAS definitions,

using the Name and Status of the ALIAS occurrence and the physical

attributes (Length, Data type, and so on) of the ELEMENT connected to the

ALIAS using the PHY AL association.

Again, if the Copybook Import facility determines the ALIAS-ELEMENT

combination matches the element in the copybook, it re-uses the ALIAS

definition as part of the copybook definition.

Group Elements

When the Copybook Import facility encounters a group element in the copybook

it is processing, it performs these steps:

1. Compares group elements encountered in a copybook with existing GROUP

entities (the significant attributes are Group Name and Status).

2. If a matching instance is found, the facility compares the subordinate objects

(ELEMENTs, GROUPs, or ALIASes) of the group.

3. If the same subordinate objects exist in both the scanned group element and

the Repository definition of the group element, the Copybook Import facility

re-uses the GROUP occurrence.

Records and Segments

When Importing 01 levels (RECORD/SEGMENT) the Copybook Import facility

performs the following evaluations.

■ The Copybook Import process compares the Name and Status of the 01

levels of the copybook you are importing with RECORD or SEGMENT entities

in the Repository.

■ If the Copybook Import process finds a matching occurrence that it inserted

as a result of the processing of basic and group elements by the current

import process, the Copybook Import Facility will re-use the RECORD or

SEGMENT entity.

Page 52: CA Repository for z/OS - ftpdocs.broadcom.com

Copybook Import

52 Copybook Interface Product Guide

■ If the Copybook Import does not find a matching RECORD or SEGMENT, the

Copybook Import process investigates copybook definitions that are superior

to the record or segment definitions.

– If only one COPYBOOK entity connects to the RECORD or SEGMENT, and

it corresponds to the copybook you are importing, Copybook Import

updates the RECORD or SEGMENT definition with the new information.

– If multiple COPYBOOKs connect to the RECORD or SEGMENT, or only one

COPYBOOK connects to the RECORD but it does not correspond to the

copybook you are importing, the Copybook Import facility inserts a new

RECORD or SEGMENT definition.

Copybooks

When importing copybooks, the Copybook Import re-uses a copybook if it finds

a copybook with the same name, qualified data set, and language; otherwise a

new copybook is inserted.

Relationships to Records are added, deleted, and updated according to the

processes for Records and Segments described in the previous paragraph.

Copybook Import

The CA Repository for z/OS Copybook Import facility is a screen-driven

application for importing copybook and record definitions from data sets or PDS

members. The data set containing the copybook must have an LRECL of 80

bytes.

If the Copybook

is:

Columns: Are:

COBOL 8 through 72 Scanned for structure.

Note: Column 7, reserved for the

Comment symbol, is also recognized.

PLI 2 through 72 Scanned for structure.

Assembler 1 through 72 Scanned for structure.

Note: To use Copybook Import, you need authorization for the

options.copyin.record, SELECT, INSERT, UPDATE, and DELETE authorization for

a single, user-specified status.

Page 53: CA Repository for z/OS - ftpdocs.broadcom.com

Copybook Import

Chapter 3: Importing Copybooks 53

To import a copybook

1. Open the Edit window for the RECORD or COPYBOOK entity type.

2. Select Options.copyin.record from the CA Repository CLIST, ARZOS. The

Copybook Conversion screen appears.

----------------------------- Copybook Conversion ----------------------------- COMMAND ===> OPTIONS: Status? ===> DBXT (Search/Insert Status) Second Status? ===> (Search Status) Third Status? ===> (Search Status) ExtraStatus? ===> (Search/Insert Status) Scope of (E-Element, A-All objects, ExtraStatus? ===> ' ' - disregard ExtraStatus Version? ===> 0 (Insert Version 0-32767) Default Version? ===> N (L-Lowest, H-Highest, N-Next) AR/ZOS Usage? ===> DDL 01 Level Elements? ===> Y Default Prefix? ===> Prefix 88 ? ===> N (Y/N) Default Suffix? ===> Suffix 88 ? ===> N (Y/N) Language? ===> C (A-ASM,C-COB,I-IMS COB,P-PLI,L-IMS PLI,X-C) I/O Validation? ===> B (Y-Yes, N-No, B-Batch) Generate Name? ===> N (For Segment and COBOL Copybooks Only) Default 01 Record? ===> Workstation? ===> WORKTEST Process Prefixes? ===> N (Y-Yes,N-No) Min Percent? ===> 80 Process Suffixes? ===> N (Y-Yes,N-No) Delimiter Type? ===> ("C" for a single char, "#" for char count) Element Delimiter? ===> (Hyphen, Underscore, {etc. for Asm.}) Pre/Suffix Char Ct? ===> (No. of chars to select for prefix or suff.) Process Comments? ===> Y Before or After ? ===> A Input Dataset? ===> TSOID.TEST.COPYLIB(MYCOPY) Pref/Suff DSN? ===> Disposition? ===> SHR (NEW, SHR, MOD) Edit JCL? ===> Y

3. Complete all fields on this screen as described in the following table:

Field Enter

Status A status to use for all instances created as a result of the

import. CA Repository for z/OS checks this status for

existing instances it can re-use before it inserts a new

instance.

Second Status (Optional) An alternative status for CA Repository for z/OS

to search for instances. CA Repository for z/OS only checks

this status if it fails to find a reusable instance in the status

specified in Status.

Third Status (Optional) A second alternative status for CA Repository for

z/OS to search for instances. CA Repository for z/OS only

checks this status if it fails to find a reusable instance in the

status specified in Status or Second Status. If no

Page 54: CA Repository for z/OS - ftpdocs.broadcom.com

Copybook Import

54 Copybook Interface Product Guide

Field Enter

matching instance is found in this status, CA Repository for

z/OS inserts an instance in the status specified in Status.

Extra Status

Any legal status, or leave the field blank.

Scope of Extra

Status

'A' All objects.

'E' ELEMENT only.

' ' Disregard extra STATUS.

If you code both Extra Status and Scope, then Extra Status

will be searched first. When the Extra Status cannot be

found, then Status1, Status2, Status3 will be searched. If

the object still cannot be found, then the object will be

inserted into the Extra STATUS.

Version A version number to use for all instances the import

creates.

Default Version The version number to use when an existing entity has the

same name and status as an entity the copybook import

needs to create, but has different attributes. Valid options

are:

L Use the lowest available version (if version numbers 0, 1,

2, and 4 were already in use, CA Repository for z/OS would

use 3).

H Use the highest available version (initially 99).

N Use a version number that is “1 + the highest existing

version” of the entity (if the version numbers 0, 1, 2, and 4

are already in use, version 5 is used). For performance

reasons, CA suggests this option.

RzOS Usage

DDL or IMS.

01 Level Elements

Y 01 levels with a picture clause is stored as a record with

no subordinate Groups or Elements.

N 01 level elements are stored as a Record and one

subordinate Element.

Default Prefix A token or character string for CA Repository for z/OS to

consider as a prefix and to strip off of the names of

instances it inserts into the Repository. CA Repository for

z/OS stores this prefix with the COPY REC relationship it

inserts to link the copybook to the definitions of its

constituent records.

Default Suffix A token or character string for CA Repository for z/OS to

consider as a suffix and to strip off of the names of

instances it inserts into the Repository. CA Repository for

z/OS stores this suffix on the COPY REC relationship it

inserts to link the copybook to the definitions of its

Page 55: CA Repository for z/OS - ftpdocs.broadcom.com

Copybook Import

Chapter 3: Importing Copybooks 55

Field Enter

constituent records.

Language

The programming language is the copybook written. Valid

options are:

A Assembler

C COBOL

X C

P PL/I

If the copybook is being imported as a segment definition,

the two choices are:

I IMS COBOL

L IMS PL/I

Prefix 88

Y the Copybook Import process strip prefixes from 88

levels.

N to skip prefix processing on 88 levels.

Suffix 88 Y the Copybook Import process strip suffixes from 88

levels.

N skip suffix processing on 88 levels.

Page 56: CA Repository for z/OS - ftpdocs.broadcom.com

Copybook Import

56 Copybook Interface Product Guide

Field Enter

I/O Validation

The type of I/O validation to use when inserting instances

into the Repository. Valid options are:

Y Full validation. Use this option to ensure that all entities

CA Repository for z/OS inserts during the import process

conform to the status and code table standards of your site.

Any errors rollback the entire job.

N No validation. Use this option to dramatically increase the

speed at which CA Repository for z/OS processes entities.

This option bypasses procedures such as status checking

and code table validation. You will have to manually correct

any entities CA Repository for z/OS inserts with invalid

values. To use this option, you must have authority for the

CA Repository for z/OS command bload.bload.novalid.

B Batch validation. Batch validation is based on the

Repository internal entity ID. A job using batch validation

will generally run 20 to 30 percent faster than a job using

no validation. Due to contention problems, however, jobs

using batch validation cannot be run concurrently. To use

this option, you must have authority for the AR/ZOS

command bload.bload.novalid. This is the recommended

option.

Generate Name

Y uses the CA Repository for z/OS Name Gen facility to

generate an 8-character IMS name for the segment

definitions based upon the name in the 01 level of the

copybook you are processing.

Default 01 Record A name to use for the record if there is no 01 at the start of

the record structure. If you leave this field blank and there

is no 01 in the record structure, CA Repository for z/OS

inserts a RECORD entity type called “Dummy-Record”. This

field does not affect C typedef structs.

Workstation

The name of a workstation (container object) for

occurrences CA Repository for z/OS creates or uses as a

result of this import. If you decide to use a workstation, be

sure to specify a non-existing workstation to keep your

imported objects in their own logical group.

Process Prefixes Y the Copybook Import process strips prefixes from the

names of entities inserted as a result of the import.

N to skip the prefix-stripping step.

See The Prefix-Stripping Process section later in this

chapter.

Process Suffixes Y the Copybook Import process strip suffixes from the

names of entities inserted as a result of the import.

N to skip the suffix-stripping step.

Page 57: CA Repository for z/OS - ftpdocs.broadcom.com

Copybook Import

Chapter 3: Importing Copybooks 57

Field Enter

See The Prefix-Stripping Process section later in this

chapter.

Min Percent

The minimum frequency that a particular token must occur

in the fields of an individual record before the Prefix/Suffix

Scan regards it as a prefix or suffix. A value of 80, for

example, would indicate that a prefix or suffix would have

to be attached to 80% of the fields in a record structure

before the Prefix/Suffix Scan facility recognized it as a

prefix/suffix. CA recommends a percentage equal to 100.

Delimiter Type

C the delimiter is the character specified in Element

Delimiter.

N the prefix or suffix is the first or last Delimiter Number

characters.

Note: Only used by Assembler COPYIN.

Element Delimiter - (hyphen) to indicate that a hyphen separates prefixes and

suffixes from names.

_ (underscore) to indicate that an underscore separates

prefixes and suffixes from names.

Any character (Assembler only) The Assembler scanner

can use any character as a delimiter, that is, & can be a

valid delimiter.

Pre/Suffix Char Ct

Used by the Assembler Scanner. The number of characters

that make up the assembler prefix or suffix.

Process

Comments

Y the text of comments imbedded in the copybook between

fields inserted into the Repository as extended text.

Comments at the top of the Copybook are always imported.

Before or After B to indicate that comments appear in the copybook before

the data item they reference.

A to indicate that comments appear in the copybook after

the data item they reference.

Page 58: CA Repository for z/OS - ftpdocs.broadcom.com

Copybook Import

58 Copybook Interface Product Guide

Field Enter

Input Dataset

The name of the data set in which the copybook is stored.

You can use wildcards to select members from a partitioned

data set as follows:

QUAL.COPYBOOK (*) to import every member in the

COPYLIB without displaying a list.

QUAL.COPYBOOK (T*) to display a list of members that

begin with the letter T, allowing you to choose which

members to import.

QUAL.COPYBOOK (*DDL) to display a list of members

that end with the string “DDL”, allowing you to choose

which members to import.

QUAL.COPYBOOK (with no wildcards) to display a list all

members in the data set, allowing you to choose which

members to import.

Pref/Suff DSN

The name of the data set containing your site's prefixes and

suffixes. See the Prefix-Stripping Process section later in

this chapter.

Disposition

NEW to indicate the data set does not yet exist and must

be created during the execution of the Prefix Scan facility.

SHR to indicate data set already exists and that Prefix

scanner should overwrite any data it contains.

MOD to indicate the data set already exists and that the

prefix scanner should append any new data at the end of

any data already in the data set.

Edit JCL Y to display the generated JCL in an ISPF edit session (you

can then submit the job by entering SUBMIT on the

command line).

N to submit without displaying JCL.

4. Press Enter.

a. If the value for EDIT JCL was Y and a specific data set was entered in the

Input Dataset name field, the JCL is generated and displayed in your

ISPF edit session. The JCL can be reviewed then manually submitted by

entering SUBMIT on the command line.

b. If the value for EDIT JCL was Y and a partitioned data set was specified

in the Input Dataset field but a specific member name not defined, when

you select ENTER, a list of the members in the PDS is displayed. Once

member(s) are selected from the list, select PF3; the JCL is generated

and displayed in your ISPF edit session. The JCL can be reviewed and

manually submitted by entering SUBMIT on the command line.

Page 59: CA Repository for z/OS - ftpdocs.broadcom.com

Stripping Prefixes and Suffixes

Chapter 3: Importing Copybooks 59

c. If the value for EDIT JCL was N and a specific data set or PDS member

name was entered in the Input Dataset name field, the JCL is generated

and submitted.

d. If the value for EDIT JCL was N and a partitioned data set was specified

in the Input Dataset field, when you select ENTER, a list of the members

of the PDS is displayed. Once members are selected from the list, select

PF3 and the job is submitted.

Stripping Prefixes and Suffixes

One of the features of the COBOL, PL/I, and Assembler Copybook Import facility

is the ability to scan fields found in imported record structures for prefixes and

suffixes and to strip these out of the definition before attempting to insert data

into the Repository. Because it allows re-use of element definitions that are not

prefix- or suffix-specific, this facility helps to ensure that you do not populate the

Repository with redundant information when importing copybooks.

Note: This feature is not used for Assembler C typedef structs.

The Prefix-Stripping Process

Prefix/Suffix Stripping consists of two basic steps.

1. The Prefix/Suffix Stripper job scans the copybook for prefixes and suffixes

and writes any it identifies to the prefix/suffix data set.

2. When the Copybook Import job processes the record structure, it removes

prefixes or suffixes listed in the prefix/suffix data set from the names in the

basic or group element names before it compares them to instances already

in the Repository.

Page 60: CA Repository for z/OS - ftpdocs.broadcom.com

Stripping Prefixes and Suffixes

60 Copybook Interface Product Guide

The prefix/suffix data set used in the second step need not be the same

prefix/suffix data set it created in the first step. It simply needs to have the

correct format.

Copybook Conversion

Input Data Set

(Copybook)

Extracts, Prefixes and

Suffixes

Extracts Records

Strips Prefixes and

Suffixes from RecordsCopybook Import

Prefix/Suffix Stripper

Prefix/Suffix Dataset

CA Repository

The prefix/suffix-stripping program starts processing by selecting two possible

prefixes and suffixes. It takes the first possible prefix from whatever characters

precede the first element delimiter on the 01 level name. It takes the second

possible prefix from the next field in the record structure that contains an

element delimiter in its name. If these prefixes differ, the prefix-stripping

program checks to see if the one that appears more frequently exceeds the

threshold percentage-if it does, the program writes the prefix to the prefix-suffix

file for subsequent use during prefix stripping.

The program selects two possible suffixes in the same manner: the first possible

suffix is the string that follows the last element delimiter on the 01 level name

and the second possible suffix is taken from the next field in the record structure

that contains a delimiter in its name. If these suffixes differ, the suffix-stripping

program checks to see if the one that appears more frequently exceeds the

threshold percentage - if it does, the program writes the suffix to the

prefix-suffix file for subsequent use during suffix stripping.

Prefix-Stripping Examples

Suppose the following copybook was scanned:

01 CSTMR-ADDRESS.

05 CUST-STREET-ADDR PIC X(30).

05 CUST-CITY PIC X(25).

05 CUST-STATE PIC X(2).

05 CSTMR-ZIP PIC X(5).

01 EMP-ADDRESS.

05 EMP-STREET-ADDR PIC X(30).

05 EMP-CITY PIC X(20).

Page 61: CA Repository for z/OS - ftpdocs.broadcom.com

Stripping Prefixes and Suffixes

Chapter 3: Importing Copybooks 61

Assume that the prefix/suffix scanning program was then executed with the

parameters set as follows:

PARM=('/ ,COPYLIB,N,N,1,1,55,Y,Y')

The Prefix data set follows this format:

CSTMR-ADDRESS CUST- NN

EMP-ADDRESS EMP- NN

The Import step of this process inserts the following occurrences for the first

record in the copybook:

RECORD CSTMR-ADDRESS, status, 00

ELEMENT STREET-ADDR, status, 00

CITY, status, 00 (Char[30])

STATE, status, 00

CSTMR-ZIP, status, 00

The Import step inserts or re-uses the following occurrences for the second

record in the copybook:

RECORD ADDRESS, status, 00

ELEMENT STREET-ADDR, status, 00 (* reused *)

CITY, status, 01 (Char[20])

For the first record in the copybook, the import process inserted

CSTMR-ADDRESS in RECORD, and CSTMR-ZIP in ELEMENT because the

prefix-stripping determined the token CUST- (and not CSTMR-) was the prefix

for that record. This can be attributed to the fact that the fields with the prefix

CUST- outnumbered those with the prefix CSTMR- and CUST- was the only prefix

that exceeded the frequency threshold percentage (60 percent versus 40

percent against a threshold of 55 percent).

Note: The process inserted STREET-ADDR only once. The scan against the

record called EMP-ADDRESS was able to re-use that ELEMENT. Finally, notice

that the import inserted CITY twice due to the difference between significant

attributes (in this case, Length).

Page 62: CA Repository for z/OS - ftpdocs.broadcom.com

Stripping Prefixes and Suffixes

62 Copybook Interface Product Guide

The generation of these two record structures place the prefixes captured and

stored within the COPY REC relationships in front of all of the basic and group

elements connected to the records. When generating these records, you can use

the Prefix 01 and Prefix 88s options on the DDL Manager window to determine

whether the 01 and 88 levels will be prefixed with the prefixes stored in COPY

REC. You can also override the prefix stored in COPY REC by specifying a new

string of characters in the Prefix option of the DDL Manager window. These

same options also apply to suffixes.

The Prefix-Suffix File

During the scanning step of the prefix-suffix process, the Prefix-Suffix programs

write prefixes and suffixes it detects to a data set known as the prefix-suffix file.

The second step of the process uses the information in this data set to determine

which prefixes and suffixes it should strip from record, group, and element

names before inserting instances into the Repository.

This Prefix-suffix file has an LRECL of 80 bytes and stores information in the

following format:

Record Name(w/Prefix) Pos(001) Length(032)

Prefix (with delimiter) Pos(033) Length(015)

Suffix (with delimiter) Pos(048) Length(015)

Do not strip 01 prefix Pos(063) Length(001)

Do not strip 01 suffix Pos(064) Length(001)

When using the Copybook Import facility, you can use the prefix file created

during the scanning phase of the prefix-stripping process or you can use an

alternate file you have prepared.

To use the prefix-suffix file created during the scanning phase of the

prefix-stripping process

1. Type Y in the Process Prefixes and Process Suffixes fields of the

Copybook Conversion screen.

2. Specify the name of a data set in the Prefix/Suffix DSN field.

To use an alternative prefix-suffix file

1. Type N in the Process Prefixes and Process Suffixes fields of the

Copybook Conversion screen.

2. Specify the name of a data set in the Prefix/Suffix DSN field.

Page 63: CA Repository for z/OS - ftpdocs.broadcom.com

Stripping Prefixes and Suffixes

Chapter 3: Importing Copybooks 63

Edit the Prefix-Stripping JCL

The JCL for running the stripping program contains a parameter string that you

can alter to affect how the job is processed. To edit this parameter string, make

certain you set the Edit JCL field in the Copybook Import screen to Y.

The layout for the parameter string for COBOL and PLI is:

PARM=('DEBUG, INPUT-TYPE, NO-STRIP-P, NO-STRIP-S,

N-DASH-P,N-DASH-S,PERCENT, PROCESS-PREFIX, PROCESS-SUFFIX')

The Assembler prefix stripping program uses PARMFILE to contain the

parameters. The following table describes the purpose of each of these

parameters.

Parameter Specify

DEBUG Leave blank to turn off debug statements.

Y to instruct the job to produce AR/ZOS Debug statements, which

aid in the identification and resolution of problems encountered

during the execution of a CA Repository for z/OS process. These

statements will be sent to the data set specified in the SYSPRINT

file (recommended LRECL = 80).

INPUT-TYP

E

COPYLIB

NO-STRIP-

P

Y to prevent COPYIN from removing prefixes from 01 levels.

N to strip prefixes from 01 levels during the import.

If you want to strip prefixes from some records but not from

others, you need to edit column 63 of the prefix/suffix data set

before executing the Import step that follows the prefix/suffix

scan step.

NO-STRIP-

S

Y to prevent COPYIN from removing suffixes from 01 levels.

N to strip suffixes from 01 level during the import.

If you want to strip suffixes from some records but not from

others, you need to edit column 64 of the prefix/suffix data set

before executing the Import step that follows the prefix/suffix

scan step.

Page 64: CA Repository for z/OS - ftpdocs.broadcom.com

Stripping Prefixes and Suffixes

64 Copybook Interface Product Guide

Parameter Specify

N-DASH-P

1 to indicate that the prefix ends at the first delimiter in the

record.

2 to indicate that the prefix ends at the second delimiter in the

record.

For example, for a record named CUST-REC-ACCOUNT-INFO:

If you set N-DASH-P to 1, the prefix is CUST-

If you set N-DASH-P to 2, the prefix is CUST-REC-

If a 2 is specified in this parameter and the fields contain only one

dash, then no prefixes are stripped.

N-DASH-S 1 to indicate that the suffix starts at the last delimiter in the

record.

2 to indicate that the suffix starts at the second-to-last delimiter

in the record.

PERCENT

The threshold percentage of fields in a record that must begin

with a certain token before that token is recognized as a prefix or

suffix. This parameter is passed from the Min Percent field of the

Copybook Conversion screen.

PROCESS-P

REFIX

Y to have the Copybook Import process strip prefixes from the

names of entities inserted as a result of the import.

N to skip the prefix-stripping step.

PROCESS-S

UFFIX

Y to have the Copybook Import process strip suffixes from the

names of entities inserted as a result of the import.

N to skip the suffix-stripping step.

Element

Delimiter

Used by Assembler to determine the assembler prefix and suffix.

The delimiter can be any character.

Delimiter

Number

The number of characters in the prefix or suffix.

Note: Used in Assembler only.

Delimiter

Type

C if a character is the assembler delimiter.

Note: C must be specified in COBOL and PLI.

N if the prefix or suffix consists of a specific number of characters.

Note: N is used by Assembler only.

Note: The prefix or suffix (stripped from the basic or group elements) is stored

in the COPY REC relationship type, whether or not the prefix or suffix is stripped

from the 01 level.

Page 65: CA Repository for z/OS - ftpdocs.broadcom.com

Import Limitations

Chapter 3: Importing Copybooks 65

Import Limitations

The Copybook Import facility does not support the following items and features.

All Languages:

■ If a group appears more than once in a record, a subsequent occurrence of

the group will be versioned

■ Groups within a record are not used

Assembler Limitations

■ Assembler macros are not supported

■ ORG operations with no operands are not supported

PL/I Limitations

■ GENERIC items are not supported

■ LABEL items are not supported

■ SUB redefining items (explicit definitions) are not supported

■ ENTRY items are not supported

■ FILE items are not supported

■ OFFSET items are not scanned into the Repository

■ LIKE definitions are not scanned into the Repository

■ Only 12 dimensions can be imported

■ PL/I BUILTIN function declarations are not supported and may cause the

copybook import program to terminate abnormally

Page 66: CA Repository for z/OS - ftpdocs.broadcom.com
Page 67: CA Repository for z/OS - ftpdocs.broadcom.com

Chapter 4: Generating Records and Copybooks 67

Chapter 4: Generating Records and

Copybooks

This chapter describes how to use the DDL Manager for DB2 to generate

copybooks, record layouts, and field declarations using the data stored in the

Repository.

This section contains the following topics:

Generate Record Layouts (see page 67)

Generate Copybooks (see page 70)

Generate Record Layouts

Once you have inserted the necessary entities into the Repository, either using a

Repository editor or the Quick Record facility, you can use the DDL Manager to

generate a record layout or field declaration for COBOL, PL/I, or Assembler

programs.

To generate a record layout

1. Open the Edit window for the RECORD entity type. The entity type you

access depends on which item you want to generate.

2. Select the entity you want to generate. You need to tag the entity row if you

are using the Edit window in the horizontal mode.

Page 68: CA Repository for z/OS - ftpdocs.broadcom.com

Generate Record Layouts

68 Copybook Interface Product Guide

3. Use options.ddldb2 to open the DDL Generation window for Records or

options.ddlims to open the DDL Generation window for Segments.

SIZE ----- AR/ZOS DDL MANAGER FOR DB2 - 1 ENTITY SELECTED ----- MAX ¦ MAINTAIN UTILS OPTIONS PROFILE NAVIGATE HELP ¦ ¦ ENTER RECORD SPECIFICS: ¦ ¦ SAVE OUTPUT? ===> Y (Y OR N) SUBMIT BATCH? ===> Y (Y OR N) ¦ ¦ EDIT OUTPUT? ===> Y (Y OR N) EDIT JCL? ===> Y (Y OR N) ¦ ¦ EXECUTE? ===> Y (Y OR N) DDL USAGE? ===> DDL ¦ ¦ DDL COMMENTS? ===> Y (Y OR N) ¦ ¦ ¦ ¦ LANGUAGE? ===> C (C,P,A,X) LEVELS? ===> 01;02 ¦ ¦ INCLUDE 01? ===> (Y OR N) INIT REC? ===> Y (Y OR N) ¦ ¦ PREFIX 01? ===> (Y OR N) PREFIX? ===> ¦ ¦ SUFFIX 01? ===> (Y OR N) SUFFIX? ===> ¦ ¦ PREFIX INDEX? ===> N (Y OR N) SUFFIX INDEX? ===> N (Y OR N) ¦ ¦ GEN 88 LVLS? ===> N (Y OR N) PREFIX 88? ===> N (Y OR N) ¦ ¦ SUFFIX 88? ===> N (Y OR N) Gen Ent PL/I? ===> Y (Y OR N) ¦ ¦ COMMENTS? ===> B (A(AFTER), B(BEFORE) OR N(NO)) ¦ ¦ ¦ ¦ SEQUENTIAL OR PARTITIONED OUTPUT DATA SET: ¦ ¦ DATA SET NAME ===> 'TSOID.TEST.RECORDS(RECOUT)' ¦ ¦ DISPOSITION ===> SHR (MOD OR SHR) ¦ *************************************************************** -----

4. Complete the fields and switches described in the following table:

Field Enter

Save Output Y to save the generated record layout. If you elect to save

the record, you must specify a data set name in Data Set

Name.

Edit Output Y to display the generated record in an ISPF edit session.

Execute Y to run the generated JCL and create the record.

DDL Comments Y to include a comment block (SPUFI comment form)

containing your user ID and the current date and time in

the generated DDL.

Include 01 Y to include 01 levels in the copybook syntax.

Note: This option is only used as an override when

generating at the record level.

Language

C to generate records for use with COBOL.

P to generate records for use with PL/I.

A to generate records for use with Assembler.

X to generate records for use with C.

Init Rec Y to include an initialized clause in the record.

Prefix 01 Y to add the prefix specified in Prefix to the 01 level of

the record.

Page 69: CA Repository for z/OS - ftpdocs.broadcom.com

Generate Record Layouts

Chapter 4: Generating Records and Copybooks 69

Field Enter

Suffix 88 Y to add the string specified in Suffix to any 88 level

names.

Submit Batch Y to submit the generated syntax in batch.

N to submit the generated syntax online.

Edit JCL Y to display the generated JCL in an ISPF edit session (you

can then submit the job by entering SUBMIT on the

command line).

DDL Usage DDL or IMS.

Prefix

A prefix for names in the record.

Prefix 88 Y to add the string specified in Prefix to any 88 level

names.

Levels The level numbers you want used in the record, separated

by semicolons.

Gen 88 Lvls Y to include 88 level values in record.

Suffix A suffix for any names in a generated copybook.

Suffix 01

Y to add the string specified in Suffix to the 01 level of the

record.

Prefix Index Y to add the string specified in Prefix to any Index

names.

Suffix Index Y to add the string specified in Suffix to any Index

names.

Gen Ent PL/I Y to generate Enterprise PL/I for z/OS syntax.

COMMENTS

A (AFTER) or B (BEFORE) to generate comments.

N (NO) to stop comments from being generated.

Data Set Name The name of the data set in which the to store the record.

You can use either a sequential data set or a partitioned

data set and member.

Disposition SHR to replace the contents of the data set specified in

Data Set Name.

MOD to append the generated syntax to the end of any

data already in the data set specified in Data Set Name.

5. Use maintain.create to generate the record (on-line) or JCL (batch).

Page 70: CA Repository for z/OS - ftpdocs.broadcom.com

Generate Copybooks

70 Copybook Interface Product Guide

Generate Copybooks

Once you have inserted the necessary entities into the Repository (either using

the a Repository Editor or the Quick Record facility), you can use the DDL

Manager to generate copybooks for COBOL, PL/I, or Assembler programs.

To generate a copybook

1. Open the Edit window for the COPYBOOK entity type.

2. Select the entity that defines the copybook you want to generate. Tag the

entity row if you're using the Edit window in the horizontal mode.

3. Use options.ddldb2 to open the DDL Generation window for Records or

options.ddlims to open the DDL Generation window for Segments.

SIZE ----- AR/ZOS DDL MANAGER FOR DB2 - 1 ENTITY SELECTED ----- MAX ¦ MAINTAIN UTILS OPTIONS PROFILE NAVIGATE HELP ¦ ¦ ENTER COPYBOOK SPECIFICS: ¦ ¦ SAVE OUTPUT? ===> Y (Y OR N) SUBMIT BATCH? ===> Y (Y OR N) ¦ ¦ EDIT OUTPUT? ===> Y (Y OR N) EDIT JCL? ===> Y (Y OR N) ¦ ¦ EXECUTE? ===> Y (Y OR N) DDL USAGE? ===> DDL ¦ ¦ DDL COMMENTS? ===> Y (Y OR N) ¦ ¦ ¦ ¦ LANGUAGE? ===> C (C,P,A,X) LEVELS? ===> 01;02 ¦ ¦ INIT REC? ===> Y (Y OR N) GEN 88 LVLS? ===> N (Y OR N) ¦ ¦ PREFIX 88? ===> N (Y OR N) SUFFIX 88? ===> N (Y OR N) ¦ ¦ PREFIX INDEX? ===> N (Y OR N) SUFFIX INDEX? ===> N (Y OR N) ¦ ¦ SUFFIX 88? ===> N (Y OR N) Gen Ent PL/I? ===> Y (Y OR N) ¦ ¦ COMMENTS? ===> B (A(AFTER), B(BEFORE) OR N(NO)) ¦ ¦ ¦ ¦ SEQUENTIAL OR PARTITIONED OUTPUT DATA SET: ¦ ¦ DATA SET NAME ===> 'TSOID.TEST.COPYLIB(COPYOUT)' ¦ ¦ DISPOSITION ===> SHR (MOD OR SHR) ¦ *************************************************************** -----

4. Complete the fields and switches described in the following table.

Field Enter

Save Output Y to save the generated copybook. If you elect to save the

record, you must specify a data set name in Data Set Name.

Edit Output Y to display the generated copybook in an ISPF edit session.

Execute Y to run the generated JCL to create the copybook.

DDL

Comments

Y to include a comment block (SPUFI comment form)

containing your user ID and the current date and time in the

copybook.

Language C to generate copybooks for use with COBOL.

P to generate copybooks for use with PL/I.

A to generate copybooks for use with Assembler.

Page 71: CA Repository for z/OS - ftpdocs.broadcom.com

Generate Copybooks

Chapter 4: Generating Records and Copybooks 71

Field Enter

X to generate copybooks for use with C Language.

Init Rec Y to include an initialized clause in the copybook.

Suffix 88 Y to add the appropriate record suffix to any 88 level names in

the copybook.

Submit Batch Y to submit the generated syntax in batch.

N to submit the generated syntax online.

Edit JCL Y to display the generated JCL in an ISPF edit session (you can

then submit the job by entering SUBMIT on the command

line).

N to submit without displaying JCL.

DDL Usage DDL or IMS.

Prefix 88 Y to add the appropriate record prefix to any 88 level names in

the copybook.

Levels

The level numbers you want used in the copybook, separated

by semicolons.

Gen 88 Lvls Y to include 88 level values in copybook syntax.

Gen Ent PL/I Y to generate Enterprise PL/I for z/OS syntax.

COMMENTS A (AFTER) or B (BEFORE) to generate comments.

N (NO) to stop comments from being generated.

Data Set

Name

The name of the data set in which the to store the copybook.

You can use either a sequential data set or a partitioned data

set and member.

Disposition SHR to replace the contents of the data set specified in Data

Set Name.

MOD to append the generated syntax to the end of any data

already in the data set specified in Data Set Name.

Page 72: CA Repository for z/OS - ftpdocs.broadcom.com

Generate Copybooks

72 Copybook Interface Product Guide

5. Use the maintain.create command to generate the copybook (online) or

JCL (batch).

The following example shows a copybook generated with the DDL Manager

for DB2:

Page 73: CA Repository for z/OS - ftpdocs.broadcom.com

Chapter 5: Reports 73

Chapter 5: Reports

This chapter describes the CA Repository for z/OS reports designed to provide

information about DB2 objects defined in the Repository.

The DDL Manager includes several special reports to help analyze the Record and

Copybooks related metadata in the Repository. These include:

■ Enhanced Element Detail Report

■ Record Offset Report

All of these reports can be produced through the CA Repository for z/OS Print

facility. The operating procedures of the Print facility are discussed in the

“Printing Reports” chapter of the User Guide.

This section contains the following topics:

Enhanced Element Detail Report (see page 73)

Record Offset Report (see page 74)

Enhanced Element Detail Report

The Enhanced Element Detail Report provides:

■ A detailed description of the element

■ A list of code values

■ Where-used information

■ A list of logical and physical aliases and their respective where-used

information

■ A list of all elements having the same name but a different status and version

Page 74: CA Repository for z/OS - ftpdocs.broadcom.com

Record Offset Report

74 Copybook Interface Product Guide

The following figure is an example of an Enhanced Element Detail Report.

Record Offset Report

The Record Offset Report provides detailed information regarding the physical

layout of flat files and program records defined in the CA Repository for z/OS.

This report can be generated for occurrences of the RECORD entity type. The

Record Offset Report has two primary sections:

Page 75: CA Repository for z/OS - ftpdocs.broadcom.com

Record Offset Report

Chapter 5: Reports 75

The Record Information section includes the qualified name, version,

description, and the source language attributes of the record definition.

The Fields section lists the data elements (ELEMENT) that are related to the

record through FIELD relationships. This list contains the name, version, format,

length, occurrence, and position of each element.

Group Elements

If one of the elements related to the record definition is a group element, the

word GROUP appears in the FORMAT column. The end of the group element is

marked by the literal **END followed by the name of the group element. If the

group element has an OCCURS value, the position and length information for the

subordinate elements are only valid for the first iteration of the group element.

The following figure is an example of a Record Offset Report.

Page 76: CA Repository for z/OS - ftpdocs.broadcom.com

Record Offset Report

76 Copybook Interface Product Guide

Page 77: CA Repository for z/OS - ftpdocs.broadcom.com

Index 77

Index

8

88-level values

breaking links • 40

defining in Quick Record • 38

Quick 88 process • 40

A

ADD command, Quick Record • 42

ADDONLY command, Quick Record • 42

ALIAS entities • 8

aliases

COBOL records • 13

logical and physical • 12

PL/I records • 14

Assembler macros • 65

B

business name • 9

C

COBOL records • 13

COPY REC • 24

COPY SEG • 24

Copybook entity type • 23

Copybook Import facility

limitations • 65

overview • 43

population process • 50

prefix/suffix stripping • 59

prefix-suffix file • 62

prefix-suffix JCL • 63

using • 52

copybooks

Copybook Import facility • 52

generating • 70

import limitations • 65

Copybook-Segment model • 15

D

data elements • 8

DEBUG parameter • 63

DELETE command, Quick Record • 42

DELONLY command, Quick Record • 42

dimensions • 65

DSECT definitions • 47

E

ELEMENT entities • 8

elements

aliases • 12

attributes of • 9

Copybook Import facility • 50

copybook-segment model • 16

defining • 8

display attribute type description • 9

inserting in repository • 11

ENTRY items • 65

F

field, copybook-segment model • 20

fields • 20

FILE items • 65

functions, copybook-segment model • 22

G

generating records layouts • 67

GENERIC items • 65

group elements • 17

Copybook Import facility • 51

copybook-segment model • 17

I

impact analysis, Quick Record • 41

IMS segments • 49

J

JCL, prefix-suffix • 63

L

LABEL items • 65

LIKE definitions • 65

LOGIC AL associations • 8

logical alias • 12

M

models, Copybook Segment • 15

Page 78: CA Repository for z/OS - ftpdocs.broadcom.com

78 Copybook Interface Product Guide

N

NO-STRIP-P • 63

NO-STRIP-S • 63

O

OCCURS • 75

OFFSET items • 65

ORG operations with no operands • 65

P

PHY AL associations • 8

physical alias • 12

picture clause • 9, 16, 18

prefixes, stripping in Copybook import • 59

prefix-suffix file • 62

prerequisites • 7

Q

Quick 88 window • 38

Quick Record

add detail to elements • 32

changing existing record definitions • 41

define 88-level values • 38

define functions • 35

define group elements • 34

element comparison • 37

impact analysis • 41

insert RECORD entity • 30

link record to elements • 31

migrating record layout definitions • 42

overview • 26

process record definition • 37

REFRESH command • 38

SEQ field • 41

undo changes • 38

window

example • 28

field descriptions • 28

opening • 28

R

REC MAP relationships

copybook-segment model • 21

record definition structure

basic • 26

Record Offset report • 74

records

Copybook Import facility • 52

copybook-segment model • 18

defining • 41

Quick Record • 26, 30

generating • 67

REFRESH command • 38

reports

Record Offset • 74

S

segments, Copybook Import facility • 52

sequence, maintaining in Quick Record • 41

SUB ELS set • 8

SUB redefining items • 65

suffixes, stripping in Copybook import • 59

V

value, copybook segment model • 23

W

windows

Element ViewEdit • 32

Quick 88 • 38

Quick Record • 28

workstation commands

ADD • 42

ADDONLY • 42

DELETE • 42

DELONLY • 42

overview • 42