The mechanism that Oracle Forms used to coordinate the population of the detail block with the current record in the master block is the Copy Value from Item property on the foreign-key item in the detail block. The Copy Value from Item property specifies the primary-key item in the master block whose value gets copied to the foreign-key item in the detail block whenever a detail record is created or queried.
Since the value of the primary-key item in the master record gets copied to the foreign-key item in the detail block, it is automatically incorporated in the WHERE clause of the SELECT statement that Oracle Forms issues to populate the detail block.
In the following example, the value of the foreign-key item WAREHOUSE.REGION_ID is copied from the current value of the primary-key item REGION.ID. Thus, only warehouses that are in the currently selected master region get queried during block coordination.
SELECT id, address, phone, manager_id
FROM warehouse
WHERE warehouse.region_id = foreign key value
When blocks are related through a compound join, the Copy Value from Item property is set on two or more foreign-key items in the detail block.