This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

External Database - Connect multi-select

I'm using the external Database to sync a lot of records that can change.

I've got one set where Part A can go onto Models 1 - 10.

I've got my model ObjectIDs set to:
1-1
1-2
1-3
...
1-10



For Part A. Has the multi-select Field Models.
I know how to add 1 entry to it with the model-ID

Is there the possibility to have the multi-select host links to values 1-10?

Would I need to adjust the SQL to provide a ModelID of:

{1-1,1-2,1-3,...,1-10}
or just
1-1,1-2,1-3,...,1-10

The end goal is for the External Connection to update these records:


Or would there be some other way to split the field to have an entry from my Relational Database provide all the models that an item is related to?

Or would this be an exercise in running a periodic script to go update all these values and place them inside the ModelID multi-select?

I hope that is clear enough,

Thanks in advance!

  • It is not quite clear to me whether your structure is tree-like where each object has one parent and multiple children, or there is many relations on both sides?

    If it is a tree-like structure you can sync each object type with a reference to its parent, and then have Compliance Kit, Managed Properties set the reverse relation on the parent to make it point to all of the child objects.

  • Interessting question. I understand what you want. I cannot remember where I found this info (I am sure Joonas can help), but you are supposed to return multiple rows in this case, e.g.:

    Object ID         Linked Lookup Objekt ID
    1                      54
    1                      55
    1                      56

    This should create ONE object with ID=1 and link it to the 3 objects 54,55 and 56.

    However, it never really worked for me. Not sure whether this is a bug or I just did something wrong.

  • You have at least these options:

    1. Store the values on multiple rows in the external database, one value per row, like Dorean suggested. The user guide has an example of this in the note in step 22: https://userguide.m-files.com/user-guide/latest/eng/Connection_to_external_database.html
    2. Store the values with a delimiter, for instance "1-1;1-2;1-3" like you said, and map this column to a text property in the object type settings. Then use an event handler script to parse and split the text string and add the entries to the multi-select property. The intermediary text property can be hidden from users.