Skip to content
Astera Technology

Validate that two selected records share the required context

Express a relationship check that individual field validity cannot supply.

Compare the rule with concrete cases

Fictional assignment selects a project and a checklist. Each must exist, and the checklist must belong to that project. P1 and C2 both exist, but C2 belongs to P2. Their individual validity does not make P1/C2 a valid pair.

Filled synthetic modelling cases
Selected projectSelected checklistChecklist owner projectPair valid
P1C1P1Yes
P1C2P2No
P2C2P2Yes
Download editable CSV ↓

Work through the distinction

The condition compares the relationship reference, not similar titles. A checklist called “General” does not become usable for every project merely because its display name is generic.

P1 is changed to P2 while C1 remains selected. What must be rechecked?

Show the worked answer

Recheck the pair. C1 belongs to P1, so the updated P2/C1 combination is invalid.

Acceptance wording to adapt

Before saving an assignment, verify both references exist and checklist.project_id equals selected_project_id. Re-evaluate this condition when either selection changes; reject a mismatched pair.

Related resources