Hi @Anonymous ,
Do you want to use collection to update sharepoint list?
Firstly, let me explain why you did not succeed:
The formula that you use needs the fields' data type in collection and in list are the same.
Since comment_1 and comment are both text type, you could directly use { comment: comment _1} to get value.
However, for complex data type( lookup, choice), you need complex formula.
Could you tell me shop_name looks up to which field in "SP_Shop”SharePoint List? and that field's data type?
I assume that shop_name looks up to Title field in "SP_Shop”SharePoint List and Title field is text type.
If so, please try this:
ForAll(coll_customer,
Patch(SP_customer,
First(Filter(SP_customer ,ID =ID_1)),
{ comment: comment _1,
shop_name: RenameColumns(
AddColumns(
Split(shop_name_1,";#"),
"Id",
LookUp(SP_Shop,Title=Result,ID)
),
"Result","Value"
),
category:RenameColumns(Split(category_1,";#"),
"Result","Value"
)
}
)
You need to notice the structure of multiple lookup field and multiple choice field.
Multiple lookup field is a table with two columns named Value and Id.
Multiple choice field is a table with one column named Value.
So you need to re-shape text value to the structure that the purpose field needs.
What's more, you not only need to connect your app with SP_customer list, but also need to connect your app with SP_Shoplist.
(You need the related field's ID value to update lookup field.)
Best regards,