Bridge key

A Bridge key is a multi-columns reference check in two tables. It may contain one or more many-to-many columns relationships of another table.

A Bridge key will identify referential integrity check for one or more columns data which has not been referenced by the selected columns of the referenced table.

  • For example:

If the base table is LINEITEM, base columns is L_PARTKEY, L_SUPPKEY reference table is PARTSUPP, and reference columns is PS_PARTKEY, PS_SUPPKEY then the check is defined as

  • (not exists (select PARTSUPP.PS_PARTKEY , PARTSUPP.PS_SUPPKEY from PARTSUPP where PARTSUPP.PS_PARTKEY=LINEITEM.L_PARTKEY and PARTSUPP.PS_SUPPKEY=LINEITEM.L_SUPPKEY)). Here, if the LINEITEM.L_PARTKEY and LINEITEM.L_SUPPKEY columns value does not match with PARTSUPP.PS_PARTKEY and PARTSUPP.PS_SUPPKEY then those base table records are considered as invalid.

 

Steps to create bridge key rule in uArrow:
1. Click + Add button in the bridge key rule for columns L_PARTKEY and L_SUPPKEY.

2. You can define bridge key details using below parameters.

Parameter Name Description
Rule Description Specify the rule description.
Rule Category Choose or create new dimension to classify rule if required.
Bridge Table Choose reference table using select box.
Bridge Columns Choose relevant columns as bridge columns from select box, you can select more than one column.
Mapping Choose relevant source columns from select box.

Click “Apply” to reflect the new changes, and then click “Save” button to save the job.

Menu