As a part of a referential integrity check

Code tables may be used to define standard referential integrity checks in the LANSA repository or in LANSA RDML functions. For example you might need to check that a state code "NT" that has arrived from someone else's application is a valid state code. 

Only tables with data that is stored in a physical table (either user defined or the generic Framework table storage table FPTAB) allow referential integrity checks.

In the RDML, a check against a code table named VF_STATES would look like:

*Use the index (kya) keyed by:

*Table name, AKey1, Nkey1, AKey2, Nkey 2, Akey3, Nkey3 ..., field name 




A LANSA table validation check against the employee table would look like this