When we have a many-to-many association it needs to be in a basket. Having multiple datasets leads to multiple possible baskets for it. When I create a new feature that is connected over the association, I can choose it's basket, but I can't choose it for the linking-feature.
Example
0. Having this model
INTERLIS 2.3;
/* Ortsplanung as national model */
MODEL WheresTheAssoc_V1 (en) AT "https://modelbaker.ch" VERSION "2024-02-07" =
TOPIC Infrastruktur =
CLASS Item =
Text : TEXT;
END Item;
END Infrastruktur;
TOPIC Unterhalt =
DEPENDS ON WheresTheAssoc_V1.Infrastruktur;
CLASS Instandsetzung =
Text : TEXT;
END Instandsetzung;
ASSOCIATION InstandsetzungItemAssoc =
Item (EXTERNAL) -- {0..*} WheresTheAssoc_V1.Infrastruktur.Item;
Instandsetzung -- {0..*} Instandsetzung;
END InstandsetzungItemAssoc;
END Unterhalt;
END WheresTheAssoc_V1.
1. Having those baskets
2 datasets x 2 topics -> 4 baskets
2. Create Item in TG
3. Create linked Instandsetzung in TG
But here we have the default basket selected in the Dataset Selector for "Baseset". We change to TG and store
Result
The linking table has still the default basket, what is wrong.
Sollution
In this case here, where we have one link to an EXTERNAL class and one link to an internal class, it could be a solution to take always the basket of the internal parent:
But I neither have checked out if this solves it in every case (what if both parents are external?) nor I know if it could affect the performance too much....
When we have a many-to-many association it needs to be in a basket. Having multiple datasets leads to multiple possible baskets for it. When I create a new feature that is connected over the association, I can choose it's basket, but I can't choose it for the linking-feature.
Example
0. Having this model
1. Having those baskets
2 datasets x 2 topics -> 4 baskets
2. Create Item in TG
3. Create linked Instandsetzung in TG
But here we have the default basket selected in the Dataset Selector for "Baseset". We change to TG and store
Result
The linking table has still the default basket, what is wrong.
Sollution
In this case here, where we have one link to an EXTERNAL class and one link to an internal class, it could be a solution to take always the basket of the internal parent:
But I neither have checked out if this solves it in every case (what if both parents are external?) nor I know if it could affect the performance too much....