DSNIRELI

DSNIRELI is part of the Data Manager component of Db2 and is involved in insert processing for tables defined with referential integrity constraints.

Hints

This module appears with the insertion of a row into a table that has been defined with a foreign key.

Referential constraints can negatively impact insert performance since insert operations on a foreign key may require repeated references to the same primary key value in a parent table.

For mass inserts, consider dropping the target table's referential constraints, inserting rows through the LOAD utility, replacing the constraint and running the CHECKDATA utility to verify the referential validity of the inserted rows and reset the CHECKPENDING status of the table.

Foreign keys should be indexed to prevent the use of tablespace scans to enforce referential constraints. The leading columns of the index should match the columns of the foreign key.

Consider placing tables bound by relational constraints in the same tablespace when foreign keys have been indexed, but place them in separate spaces when foreign keys are unindexed to prevent unnecessary scanning.

Reference Sources

IBM Db2 for OS/390, Messages and Codes, GC26-8979

IBM Db2 for OS/390, Application Programming and SQL Guide, SC26-8958