Previous Topic: Successful Execution Requirements and ControlsNext Topic: Parallel Extract


How to Use

You can execute this command in either Single User or with the MUF active. Execute the EXTRACT function using the following command format:

Extract Data Table Native (z/OS)

►►─ EXTRACT AREA=a,DBID=n,DDNAME=d,TABLE=t ─┬──────────────┬──────────────────►
                                            └─ ,BLKSIZE=n ─┘

 ►─┬───────────────┬─┬──────────────┬─┬───────────────────────┬───────────────►
   └─ ,FIRSTKEY=n ─┘ └─ ,LASTKEY=n ─┘ └─ ,MULTUSE= ─┬─ NO ──┬─┘
                                                    └─ YES ─┘

 ►─┬────────────────┬─┬───────────────┬─ ,SEQ=NATIVE ─────────────────────────►◄
   └─ ,SEQBUFS=nnn ─┘ └─ ,SLACK=nnnn ─┘

Extract Data Table Physical (z/OS)

►►─ EXTRACT AREA=a,DBID=n,DDNAME=d,TABLE=t ─┬──────────────┬──────────────────►
                                            └─ ,BLKSIZE=n ─┘

 ►─┬────────────────┬─┬───────────────┬─ ,SEQ=PHYSICAL ───────────────────────►
   └─ ,SEQBUFS=nnn ─┘ └─ ,SLACK=nnnn ─┘

 ►─┬───────────────────────┬──────────────────────────────────────────────────►◄
   └─ ,UPDATE= ─┬─ NO ◄ ─┬─┘
                └─ YES ──┘

Command

EXTRACT

Invokes the function to extract data in expanded form.

Required Keywords

AREA=

Identifies the data area containing the table.

Code *** (three asterisks) to use the Full Parent name, that is, if you are extracting a partition Full Parent table.

Valid Entries:

DATACOM-NAME of the area, or *** to extract a partition Full Parent table

Default Value:

(No default)

,DBID=

Identifies the database for the area to be read.

Valid Entries:

DATACOM-ID of the database

Default Value:

(No default)

,DDNAME=

Specifies the JCL DDNAME for the output data set. This name must match the corresponding name in the JCL.

A DDNAME is not acceptable for sequential input or output files if it is a name reserved for a CA Datacom area. Names with the following patterns are therefore not acceptable for DDNAME=:

,TABLE=

Specifies the name of an individual table to be extracted.

Valid Entries:

DATACOM-NAME of the table

Default Value:

(No default)

Optional Keywords

,BLKSIZE=

Indicates the block size for the output data set. The number supplied with this keyword overrides the block size supplied in your JCL. If block size is specified in the JCL and this keyword is not used, the JCL block size is used. In the absence of either this parameter or a specification in the JCL, the utility uses a default as specified below.

Valid Entries:

For fixed-length tables: An integer value that is a multiple of the table record length.

For variable-length tables (CA Datacom VSAM Transparency): An integer value that is at least the length of the longest record plus 8.

Default Value:

The default for BLKSIZE= when running z/OS is 0 (zero), which defaults to the z/OS default. That default is large and optimized for the particular device type, that is, the most optimal default for sites executing this operating system.

,FIRSTKEY= and/or ,LASTKEY=

These keywords allow you to select a segment of a table or area by Native Key (SEQ=NATIVE) value to be processed for EXTRACT. The EXTRACT function normally defaults to include the full Native Key range from low values to high values. FIRSTKEY= overrides the default starting position while LASTKEY= overrides the default ending position, limiting the records retrieved for output to the EXTRACT file. If one keyword is specified and the other is not specified, a default value is selected for the missing keyword. Normal CA Datacom key lengths are from 1 through 180 bytes. The key value data entered for FIRSTKEY= and LASTKEY= can be from 0 (zero) through 59 bytes long. You only need to code the number of positions of the key value that are significant to you, but be aware that the value coded is left justified regardless of key field data type. The utility pads the low order or remaining positions of the key value with low values on FIRSTKEY= and high values on LASTKEY=. To extract the entire area in one step, specify neither FIRSTKEY= nor LASTKEY=. Alternately, you could specify FIRSTKEY=00 and/or LASTKEY=00 which causes processing to start at low values and end at high values. The length of zero indicates that the padded key values (low values and high values) are to be used.

The data is not edited or interpreted. Therefore, if the key value data you need to enter is in binary, you must set up the JCL using a hexadecimal mode display and enter the key value data in hexadecimal. This data can contain blanks, commas, and any other special characters. CA Datacom/DB cannot edit this data for syntax, so the control statement can look invalid, especially when it includes blanks or commas or key value data containing English words. For example, FIRSTKEY=12121212121212 means the length is 12, key value is 121212121212. Another example, FIRSTKEY=10FIRSTKEY10 means the length is 10, key value is FIRSTKEY10.

Valid Entries:

A 2-byte length (in the range of 00 through 59) followed by a character string of key value bytes (for the length specified) that represents the key value.

Default Value:

The starting/ending position of the full Native Key range from low values to high values.

,MULTUSE=

(For area level DBUTLTY control only.) If you specify MULTUSE=, do not specify SEQ=PHYSICAL.

Note: EXTRACT with a Full Parent table must not specify MULTUSE=YES.

For more information about area level DBUTLTY control, see Area Level DBUTLTY Control.

Valid Entries:

NO or YES

Default Value:

NO

,SEQ=

Indicates the sequence for the output data.

NATIVE

CA Datacom/DB reads the Index and writes the data in logical Native Key sequence. When using SEQ=NATIVE, you can use the FIRSTKEY=/LASTKEY= optional keywords to select only a portion of the table or area. One of the uses of FIRSTKEY=/LASTKEY= involves doing parallel extracts. For more information, see Parallel Extract.

PHYSICAL

CA Datacom/DB does not read the Index and outputs the data in physical track sequence.

Note: Do not specify SEQ=PHYSICAL if you specify MULTUSE=.

EXTRACT with a Full Parent table must not specify MULTUSE=YES.

Valid Entries:

NATIVE or PHYSICAL

Default Value:

NATIVE

,SEQBUFS=

With MULTUSE=YES specified, if necessary to ensure best performance DBUTLTY overrides the SEQBUFS= value either specified or defaulted. If SEQBUFS= is omitted (invoking the default value) or specified as a value 0-128 (even numbers only), the MUF treats this as though 128 was specified (or defaulted). This directs the MUF to allocate 128 private sequential buffers for use by this function. If SEQBUFS= is specified as a number 130-256 (even numbers only) the MUF treats this as though 256 was specified and uses the common data pools (64 blocks per I/O).

When MULTUSE= is omitted or specified as NO, SEQBUFS= is edited and ignored, and DBUTLTY executes with the best performance by using either the available data buffers (specified with the DATANO= parameter in the DBMSTLST macro) or available private sequential buffers.

Valid Entries:

0-256 (even numbers only)

Default Value:

128

,SLACK=

Provides record padding in the output data. This allows a larger size to be written to the output file to assist in possible record expansion. Without this parameter, the data written to the output file is in the size used by CA Datacom/DB. The pad, if any, is always blanks.

Valid Entries:

0 to 9999

Default Value:

0

,UPDATE=

Indicates whether the database can be open for update at the start or during the backup.

Note: Only valid if you specify PHYSICAL for the SEQ= keyword.

NO

Allows tables in the database to be updated and allows the INIT or LOAD functions on the data area during the backup.

YES

Specifies that CA Datacom/DB determines that the data area is loaded with a loaded Index and that the database is open for read-only with the unloading indicator set.

Valid Entries:

NO or YES

Default Value:

NO