Application programming with the IMS catalog

The IMS catalog database is accessible to standard IMS DB application programs when it is enabled for your IMS system.

Information in the IMS catalog

The IMS catalog database stores application and database metadata in a format that is accessible to standard IMS DB application programs. This information includes database definitions, program specifications, and user comments. Any application program can read this information, but the catalog database is write-protected and can be updated only by authorized system utilities such as the IMS catalog populate utility (DFS3PU00).

By default, the IMS catalog is named DFSCD000. The DFSC prefix is replaced with an alias prefix if one is defined to IMS.

Information in the IMS catalog secondary index

The IMS catalog secondary index contains a single segment type, DBDPSB. It is logically linked to the DBDXREF segment type in the IMS catalog database, which is included in all catalog records for IMS PSBs. You can use the catalog secondary index to determine which IMS programs reference a specific user database without processing the entire IMS catalog.

By default, the IMS catalog is named DFSCX000. The DFSC prefix is replaced with an alias prefix if one is defined to IMS.

IMS catalog PSBs and PCBs for application programs

IMS does not require user PSBs to contain a PCB for the IMS catalog database or secondary index. The catalog PSBs DFSCP000, DFSCP002, and DFSCP003 are dynamically attached to any user PSB that makes a DL/I call to the catalog database or issues an INIT DB QUERY call. Each PSB is intended for use by a different type of application program:

DFSCP000
High-level assembler and COBOL applications
DFSCP002
PL/I applications
DFSCP003
PASCAL applications
Restriction: The IMS catalog PSBs are not dynamically attached to generated PSBs or GSAM-only PSBs.

The following PCBs are included to support different catalog processing models:

DFSCAT00
The primary PCB to access all data in the DFSCD000 (IMS catalog) database. Use this PCB to perform standard catalog processing.
DFSCATSX
This PCB provides a SENSEG for the DBDXREF segment type in catalog PSB records and uses PROCSEQ=DFSCX000. Use this PCB to perform faster processing of the catalog database via the catalog secondary index.
DFSCATX0
This PCB provides a SENSEG for the DBDPSB segment type in catalog secondary index records. Use this PCB to process the catalog secondary index directly.

All catalog PCBs are resident. All catalog processing is performed with PROCOPT=GP.

IMS automatically increases the space allocated for the user PSB to attach the catalog PSBs. 96 bytes of additional space are allocated for each user PSB in the PSB CSA storage pool. The catalog PSB itself occupies 12kb in the DLIPSB pool and 500 bytes CSAPSB pool for each user PSB that is using the catalog PSBs. You might need to increase the size of your storage pools, up to the maximum size of the catalog PSB in each pool multiplied by the number of user PSBs that concurrently access the catalog.

GUR call

Your application program can use the Get Unique Record (GUR) DL/I call to get catalog data in the form of a single XML instance document for a particular catalog record. You can also issue other DL/I read calls to process the catalog database in the same way as any other IMS database. The GUR call is provided to reduce the number of processing steps required to retrieve a complete catalog record for a DBD or PSB.

Restriction: The use of SSA command codes is not allowed.