Version 8.2.5
 —  User, Hyperdescriptor, Collation Descriptor, and SMF Exits  —

Collation Descriptor Exits 01 - 08

The collation descriptor exits 1 through 8 (CDX01 through CDX08) are used for encoding and decoding values for the corresponding collation descriptors.

A collation descriptor may be defined for a field with alphanumeric or wide format. Its values are stored in the index, not in the record itself. The number of the collation descriptor exit used to derive the values is associated with the collation descriptor.

A sample collation descriptor exit CDXE2A is provided in the Adabas source data set. It converts EBCDIC to ASCII for the encoding function and the reverse (ASCII to EBCDIC) for the decoding function.

The Collation Exit implements three function entry points which are called on the following events:

INITIALIZE function

ENCODE function

DECODE function

This document covers the following topics:


Collation Descriptor Exit Interface

The collation descriptor exit interface is defined in the CDXPARM DSECT in the Adabas source data set. The interface has three functions:

Initialization Parameters

R1 points to a list of addresses that point to five storage areas of the caller. The collation descriptor exit must set the five areas as follows:

CDXSPC default space character; a maximum of 4 bytes
CDXSPCL fullword containing the size of the space character
CDXENC address of encoding function
CDXDEC address of decoding function If the returned address is zero, decoding is not supported. The collation descriptor cannot then be used for L9 processing.
CDXVER address of zero-byte delimited version string

graphics/init_parms.png

Encoding/Decoding Parameters

R1 points to a list of five fullword-sized parameters:

CDXIA address of the input string
CDXIL length of the input string
CDXOA address of the output string
CDXOL size of the output area
CDXARL address of the length of the returned output string

The collation descriptor exit stores

graphics/encoding_parms.png

Top of page