cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
rebeccacox
Level: Powered On

Updating a Sharepoint List from a document library

Hello! 

 

I am trying to create a flow that is triggered when an item in a document library is created or modified. The flow needs to create a new item or update an existing item. Here is what I've tried: 

 

Flow.png

 

Each time I run the flow, a new item is created, and I am unable to update existing items. 

 

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support Team
Community Support Team

Re: Updating a Sharepoint List from a document library

 

Hi @rebeccacox ,

 

Please try the following methods to achieve your needs.

  1. Use Filter Query to filter out the eligible items in the list.
  2. Use the length() function to determine whether such items exist. If they do not exist, create new items; if they exist, update the items.

Image reference:

92.PNG93.PNG

 

Best Regards,

Community Support Team _ Barry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
Super User
Super User

Re: Updating a Sharepoint List from a document library

your condition would be failing.

Copy both sides you are comapring into compose actions and observe their output for each run through the loop. Are you sure you picked the Name from trigger and the title from get items? You probally could use a filter as well on the get items and just create a item if the length is 0 as otherwise your flow will become slower and slower the more list items you end up with

Community Support Team
Community Support Team

Re: Updating a Sharepoint List from a document library

 

Hi @rebeccacox ,

 

Please try the following methods to achieve your needs.

  1. Use Filter Query to filter out the eligible items in the list.
  2. Use the length() function to determine whether such items exist. If they do not exist, create new items; if they exist, update the items.

Image reference:

92.PNG93.PNG

 

Best Regards,

Community Support Team _ Barry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
firstImage

Power Platform Online Conference

Join us for the first ever Power Platform Online Conference!

firstImage

Incoming: New and improved badges!

Look out for new contribution recognition badges coming SOON!

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Power Automate Community Video Gallery!

Top Solution Authors
Top Kudoed Authors
Users online (4,614)