Forum Discussion
Use Flow to update SharePoint list Item creating duplicate items
Need to run them as separate flows. One to Create it in the first place and one to modify the meta data if it changes.
Just created the below and it seems to work. Note: the workflows only run every 3-5mins so you won't see a change until it triggers. Hope this helps :)
Is there any way to avoid having duplicates. So every time an item is updated it creates a new item in the second list.
I am looking for something that stops that from happening.
Item creation in List 1 will lead to an item creation in List 2.
Item update in List 1 will lead to item being updated in List 2.
Right now the updating part doesn't happen. Updating item in List 1 leads to creating a new item in List 2.
- Matt WestonNov 28, 2019Iron Contributor
Hi lvk5700
I have created a couple of videos on this subject now:
FlowBites: Does it Exist (Part 1) - Filter Arrays: https://youtu.be/YLqMiDubA7s
FlowBites: Does It Exist? (Part 2) - Filter Query & Expression: https://youtu.be/x6QcntAs2_0
See if these help 🙂
- DeletedMar 08, 2019
Strange, if your filter is right then it should work fine. Because you should be using "update Item" and for me that does exactly what it says ... updates the item. It would only not do that if it could not find the item when you filtered it. What are you filtering on?
- lvk5700Mar 12, 2019Copper Contributor
Filter is set to Title eq '@{triggerBody()['Title']}'
I just tested again not all items are re-created in List 2 and some items are duplicated.
Attached screenshots of the Flow setup.
Thanks!
- Carry4_ITOct 29, 2019Copper ContributorHave you tried to add unique constraint to the SharePoint list column. That would prevent the creation of duplicates? (Tick enforce unique values, works for a subset of column types)