I have a lookup field Team in a Projects-SPO List. The field Team is linked to an another SPO-List Colleagues.
The lookup field Team can contain several Colleagues.
I use a combobox in a gallery pointing to a record in Projects to select Colleagues (items:Colleagues and DefaultItemsSelected:thisitem.Team)
When I update, only new selected Colleagues are written to the Projects-list. Existings Colleagues are gone!
Patch(Projects;LookUp(Projects;Code="TEST");
{Team: ForAll(ComboBox.SelectedItems; {'@odata.type':"#Microsoft.Azure.Connectors.SharePoint.SPListExpandedReference";
Id:ID;Value:ID})})
The instruction below gives an error (Table expected, but other schema)
Patch(Projects;LookUp(Projects;Code="TEST");
{Team:ComboBox.SelectedItems})
With dropdown (single values) linked to an other list, it works fine