CUSTOMERS (CUSTOMER_NUMBER) (Parent table, PK is CUSTOMER_NUMBER)
EVENTS (EVENT_CODE, CUSTOMER_NUMBER) (Parent table, PK is EVENT_CODE, CUSTOMER_NUMBER)
CLAIMS (CLAIM_CODE, CUSTOMER_NUMBER, EVENT_CODE) (Child table, PK is CLAIM_CODE)
The CLAIMS table needs a mandatory relation (FK) to CUSTOMERS on CUSTOMER_NUMBER
The CLAIMS table has an optional relation (FK) to EVENTS on EVENT_CODE, CUSTOMER_NUMBER
When I create the relations, the CLAIMS table ends up with two columns named CUSTOMER_NUMBER and I cannot seem to delete one of the columns or change the relation to realise that only one of the CUSTOMER_NUMBER columns should refer to both tables.
If I ignore the error, export the DDL and manually modify, then I can create the relationships.
Any help appreciated on how to force the relations to refer to the same (single) column in the child table.
BTW. Great work on this plug-in, very impressed.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I have three tables
CUSTOMERS (CUSTOMER_NUMBER) (Parent table, PK is CUSTOMER_NUMBER)
EVENTS (EVENT_CODE, CUSTOMER_NUMBER) (Parent table, PK is EVENT_CODE, CUSTOMER_NUMBER)
CLAIMS (CLAIM_CODE, CUSTOMER_NUMBER, EVENT_CODE) (Child table, PK is CLAIM_CODE)
The CLAIMS table needs a mandatory relation (FK) to CUSTOMERS on CUSTOMER_NUMBER
The CLAIMS table has an optional relation (FK) to EVENTS on EVENT_CODE, CUSTOMER_NUMBER
When I create the relations, the CLAIMS table ends up with two columns named CUSTOMER_NUMBER and I cannot seem to delete one of the columns or change the relation to realise that only one of the CUSTOMER_NUMBER columns should refer to both tables.
If I ignore the error, export the DDL and manually modify, then I can create the relationships.
Any help appreciated on how to force the relations to refer to the same (single) column in the child table.
BTW. Great work on this plug-in, very impressed.
My mistake, I should have RTFM :)
Relation by Existing Columns seems to have taken care of it.