DESCRIPTION - connect_cdc_sqdata - Latest

Connect CDC (SQData) Apply engine

Product type
Software
Portfolio
Integrate
Product family
Connect
Product
Connect > Connect CDC (SQData)
Version
Latest
Language
English
Product name
Connect CDC (SQData)
Title
Connect CDC (SQData) Apply engine
Copyright
2024
First publish date
2000
Last edition
2024-07-30
Last publish date
2024-07-30T20:19:56.898694

The DESCRIPTION command defines the structures/layouts of source and target datastores and is used in conjunction with the DATASTORE command to associate a data structure/layout with a physical datastore. DESCRIPTION commands must be specified prior to any DATASTORE commands that reference fields within a DESCRIPTION structure/layout.

The structure/layout is usually specified through a reference to an external source such as a file containing a COBOL Copybook, DDL, etc or it may be specified "In Line" in the script itself.

Syntax
DESCRIPTION <description_type> |COBOL|CSTRUCT|IMSDBD|DB2SQL|ORASQL|MSSQL|SQLDDL|XMLDTD|PL1
          <file_name> | /+in line syntactically correct description on as many lines as required+/
          AS <description_alias
          [KEY IS <key1> [,<key2>...,<keyn>]]
          [FOR SEGMENT <segment_name> IN DATABASE <dbname>]
          [TOPIC <topic>]
          [SUBJECT <subject>]
Keyword and Parameter Descriptions
Keyword Description
<description_type> Specifies the type of structure / layout used to describe a datastore. Valid description_type values are:
  • COBOL A COBOL copybook used to describe an IMS, VSAM or FILE datastore type. (See "combination" descriptions aberrations).
  • CSTRUCT A C structure used to describe a datastore.
  • IMSDBD An IMS Database Descriptor (DBD) used to describe an IMS type datastore. Note: A DESCRIPTION for the IMS DBD is required for processing IMS datastores. You must also specify a separate DESCRIPTION for each of the segments being processed within the IMS database.
  • DB2SQL DB2 Data Definition Language (DDL), such as a CREATE TABLE statement, used to describe a datastore.
  • MSSQL A Microsoft SQL Server data structure created by SQL Server Management Studio that may describe multiple tables and therefore be referenced by multiple DATASTORE commands.
  • ORASQL Oracle Data Definition Language (DDL), such as a CREATE TABLE statement, used to describe a datastore.
  • SQLDDL SQL Data Definition Language (DDL), such as a CREATE TABLE statement, used to describe a datastore. Limited DDL syntax checking compared to RDBMS specific types DB2SQL, ORASQL, MSSQL.
  • XMLDTD XML DTD statement(s) used to describe a datastore.
  • PL1 A PL1 Structure Declaration used to describe a datastore
<file_name> Specifies the name of the physical file containing the datastore description.

DD:<ddname>(<file_name>) In the z/OS environment, ddname is the name of the DD statement containing referencing a partitioned dataset (PDS) or library that references the file

./<directory_name>/<file_name> In a UNIX or Windows environment the directory_name references the appropriate "part type" type directory

/+ in line+/ When the description is specified in-line the characters "/+" and "+/" mark the beginning and ending of the structure/layout specification which may span as many lines as required.

AS <description_alias>

Specifies the alias name of the description, may contain only dash (-) and underscore (_) separators. Used as qualifier when referencing field or column names in Apply Engine script and in DESCRIBED BY clause of DATASTORE command. The aliasMUST match the VSAMDD or short system name for VSAM files defined in CICS or the RECALIAS runtime parm from the Keyed File compare capture. In our example the VSAM files are EMPLOYEE and REVIEW. The description alias will also be used as the full or partial Topic name for Kafka JSON/AVRO target DATASTORE's.

[KEY IS <key1> [,<key2>...,<keyn>]]

Optional key columns specified for target relational datastores and <description_type> DB2SQL, ORASQL or MSSQL. Only needed when the Keys cannot be retrieved from the target database manager "catalog". They are required to perform VSAM and other Keyed file updates.

One (1) or more key columns/fields (relational/VSAM) specified for target datastores used to perform an update. The type of update depends on the PROCESS command specified (CHANGE or INSERT).

[FOR SEGMENT <segment_name>] IN DATABASE <dbname>

Required ONLY for IMS datastore descriptions. This clause is used to associate the segments in an IMS database where <segment_name> corresponds to the SEGM statement in the IMS DBD file that describes the hierarchical structure of the IMS database.

[TOPIC <topic>]

Kafka DATASTORE only. Optional full or partial Kafka topic name that will be substituted for default source DESCRIPTION AS <description_alias>.

[SUBJECT <subject>]

Required when using Confluent Schema Registry, used to retrieve/maintain the AVRO schema in the Registry for the DESCRIPTION. The value chosen for SUBJECT may be made based on the capabilities of both monitoring and Kafka consumer tools that interact with the Confluent Schema Registry. The Confluent Control Center, for example, may require the SUBJECT to be the same as the TOPIC with the addition of "-value".

Example 1: DB2 source table Definition using DDL also used to describe an AVRO formatted Kafka topic

Define a Db2 source table using DDL syntax that is also used as the description for an AVRO formatted Kafka topic. Override the default Topic, the AS <description_alias> with the different value and assign a value to the SUBJECT which become part of the AVRO "schema id".
DESCRIPTION DB2SQL /home/sqdata/DB2DDL/dept.ddl AS DEPT
           TOPIC IVP_HR_DEPARTMENT
           SUBJECT IVP_HR_DEPARTMENT-value;

Example 2: z/OS Sequential File Definition

Define a z/OS data structure that is defined by a COBOL copybook. The file containing this copybook resides in a file that is referenced by DD name COBFILE(EMPLOYEE). Assign an alias of EMPLOYEE to the datastore description.
DESCRIPTION COBOL DD:COBFILE(EMPLOYEE) AS EMPLOYEE;

Example 3: IMS Database Definition using an IMS DBD and Segment Definitions

Define an IMS database structure using both the IMS Database Description (DBD) and the COBOL Segment "copybooks" in the DBD. First the IMS DBD is referenced in the member of a partitioned dataset (PDS) specified in JCL by DD name IMSDBD(IMSDBD01) and an alias name corresponding to the DBD name IMSDBD01. Next identify the two IMS segments (DEPT and EMPLOYEE) with by referencing their COBOL "copybooks" segment layouts using the DD:IMSSEG and member names DEPT and EMPLOYEE, respectively.
DESCRIPTION IMSDBD DD:IMSDBD(IMSDBD01) AS IMSDBD01;

DESCRIPTION COBOL DD:IMSSEG(DEPT)
           AS DEPT
           FOR SEGMENT DEPT
           IN DATABASE IMSDBD01;

DESCRIPTION COBOL DD:IMSSEG(EMPLOYEE)
           AS EMPLOYEE
           FOR SEGMENT EMPLOYEE
           IN DATABASE IMSDBD01;

Example 4: Relational Table Definition using inline DDL

Define a relational table using the generic description_type SQLDDL together with inline DDL statements to defined the structure, and the alias EMPLOYEE.
DESCRIPTION SQLDDL
/+
  CREATE TABLE TEST (
         FLD1     CHAR(10)
        ,FLD2     CHAR(10)
        ,FLD3     CHAR(10)
         )
+/
AS EMPLOYEE;