THANKS A LOT IN ADVANCE 🧡
Step 1) The Items in Sharepoint Library are always like this - the field "ID" is unique
Step 2)
bring the Items into an existing Excel file ( which is stored on another folder in the Sharepoint)
WORKS GOOD SO FAR !
Problem: it is not checking if the "ID" already exist, and put it in again and again
The Flow is build up like this:
1) Recurrence : every day
works✔️
2) Dateien abrufen (nur Eigenschaften) from folder "Reparaturaufträge"
works✔️
3) Variable : Name* ID, Type:Array , Value: body/value "list of elements"
works✔️
4) Choose variable: from* body/value, map* ID = union(variables('ID'),variables('ID'))
HERE is the checking missing❌
5) For Each "body/value" >> add a row into excel file table wich is matched with every single field
works✔️
Found my mistake 🙂 thanks for you help
IT WORKS !
Hi , @JuliaDRX
I create a sample test flow , you can refer to :
The "List rows present in a table" is used to check if the [ID] exist in your Excel file!
items('Apply_to_each')?['ID']
length(outputs('List_rows_present_in_a_table')?['body/value'])
You need to use your action name in your side.
If this reply can help you , you can click mark this reply as solution (Accept solution) which can help more people, thanks in advance!
Best Regards,
Yueyun Zhang
I want to add it if the ID does not exist- yes. BUT I also want no adding if the ID is already existing.
Right now I have some ID multiple time in the file - because the flow is just adding everything again and again
Hi, @JuliaDRX
Thanks for your response!
As in your screenshot , the [body/value] is the whole files return from your "Get files" action. So it will always unique.
According to your description, do you mean you want to add a row to your Excel when the [ID] column do not exist in your Excel file ?
Best Regards,
Yueyun Zhang
Hi
Yueyun Zhang, first of all thanks for your help !
I just took the "body/value"
Hi , @JuliaDRX
What's the field you put in your "Initialize variable" action?
And can you show me a screenshot for the output of your "Select" action in your flow run history.
Best Regards,
Yueyun Zhang
Michael E. Gernaey
566
Super User 2025 Season 1
David_MA
516
Super User 2025 Season 1
stampcoin
492