Referential Integrity - Teradata Tools and Utilities

Teradata® Archive/Recovery Utility Reference

Product
Teradata Tools and Utilities
Release Number
16.20
Published
March 2019
Language
English (United States)
Last Update
2019-06-05
dita:mapPath
fac1527114221922.ditamap
dita:ditavalPath
Audience_PDF_include.ditaval
dita:id
B035-2412
Product Category
Teradata Tools and Utilities

When a table is restored into a Teradata Database, the dictionary definition of that table is also restored. The dictionary definitions of both the referenced (parent) and referencing (child) table contain the complete definition of a reference.

Nonetheless, in restoring tables creating an inconsistent reference definition in the Teradata Database can happen. Hence, when either a referenced (parent) or a referencing (child) table is restored, the reference might be marked in the dictionary definition tables as inconsistent.

When a table is marked as inconsistent with respect to referential integrity, no updates, inserts or deletes are permitted. The table is fully usable only when the inconsistencies are resolved.
  • If both the referenced (parent) and the referencing (child) tables are restored, use REVALIDATE REFERENCES FOR to validate references. See REVALIDATE REFERENCES FOR.

    If inconsistent constraints remain after a REVALIDATE REFERENCES FOR statement has been executed, use ALTER TABLE DROP INCONSISTENT REFERENCES to remove inconsistent constraints.

  • If either the referenced (parent) table or the referencing (child) table is restored (but not both tables), the REVALIDATE REFERENCES FOR statement is not applicable. Use ALTER TABLE DROP INCONSISTENT REFERENCES to drop the inconsistent references.