When you define a foreign key, a field of the work area that is not contained in the foreign key table can also be assigned to a check table (for example a field of another table). This is possible for all fields except for the check field.
Table T2 is the check table of foreign key table T1. Field F of the work area is assigned to key field Field6 of check table T2.
The corresponding SELECT statement for the input check is then:
SELECT * FROM T2 WHERE T2-FIELD5 = T1-FIELD2 AND T2-FIELD6 = F.
If an entry is made in field T1-Field2 (check field), this SELECT statement will be submitted. If a corresponding record is found, the entry is valid; otherwise it is rejected.
If a field that is not contained in the foreign key table is assigned to a field of the check table, this field must be filled at the time of the input check. Otherwise the check always fails, and no values can be entered in the check field.