cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Helper V
Helper V

How to update 1 Sharepoint list item from 2 different forms

Hi all

 

I have created 2 forms with one question each. Basically it's an "I agree terms":

 

Forms 1:

1vision.JPG

 

Forms 2:

2vision.JPG

 

On the other hand, I have a sharepoint list that contains the columns to retain each of the answers.

 

vision333.JPG

 

What I would like to see if it's possible is to have the flow update/create the column values whenever the title is the same.

 

In the example above, the title (disaenz) are the same for both rows, so the expected result would be to have only one row with the "I have" in column vision and "I have" in column how are we organized.

 

Here are my 2 flows:

 

ssssfdsfsd.JPG

 

 

flow 2:

 

ldsjldsjfldslsdjf.JPG

 

How can I get one row sharing the results of both forms when the title is the same? 

 

 

Thanks!

2 ACCEPTED SOLUTIONS

Accepted Solutions
Highlighted
Super User II
Super User II

Re: How to update 1 Sharepoint list item from 2 different forms

Hi @diegoandre10 

 

I think i missed this, your condition should be different:

Here are steps:

- Get Items with Filter query -Title eq '<Response from FORM>'

GetItemFilter.jpg

- Add a condition action to check if Get Items returns any result:

     length(body('Get_Items')?['value']) >0
-  If True - Update item (as you already doing, and you dont need another condition there)
-  If False - Create Item (Like i suggested)
 
Let me know if this help.
 
Regards,
DS

 

View solution in original post

Highlighted
Community Support
Community Support

Re: How to update 1 Sharepoint list item from 2 different forms

 

Hi @diegoandre10 ,

 

You need to create two flow to update these two fields.

Both Flow structures are the same, you only need to change the Form id. When configuring Create item action and Update item action, only the specified fields need to be configured.

Spoiler
66.PNG67.PNG68.PNG

Hope this helps.

 

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

12 REPLIES 12
Highlighted
Super User II
Super User II

Re: How to update 1 Sharepoint list item from 2 different forms

Hi @diegoandre10 

 

If title is unique then you need to add a Get Items action in your second flow and query the list where Title is equal "unique Title value" , if title exist you will get the details and you can use Update item action. If not exist you can create new item.

 

Regards,

Highlighted
Helper V
Helper V

Re: How to update 1 Sharepoint list item from 2 different forms

Hi @DeepakS 

 

Thanks for the help!

 

So I did a test and partially worked. It added the item in the same row to the column called "how are we organized" for disaenz. The "I have" for the column "vision" was already created and therefore a title existed.

 

However it didnt work when it had to create a new item when the flow did not find an existing title.

 

This is my flow:

 

kpi1.JPG

saldlsadlkads.JPG

 

In other words, my if no statement to "create the item" does not work when there is not an existing title. 

 

What do you see wrong?


Thanks a lot!

 

Highlighted
Super User II
Super User II

Re: How to update 1 Sharepoint list item from 2 different forms

Hi @diegoandre10 

 

In Create Item , make sure you use Title and other details that you get from Form instead "get Item" Action.

 

Regards,

Highlighted
Helper V
Helper V

Re: How to update 1 Sharepoint list item from 2 different forms

Hi @DeepakS 

 

Not sure I got you on that one 😞

 

This is the form (1 question):

 

2vision.JPG

 

 

The create item has the title (responder email), the "vision" field is empty because that's an answer from the first form, and the "how are we organized field" has the answer from the form:

 

lsajdlsajlsajd.JPG

 

Thanks!

Highlighted
Super User II
Super User II

Re: How to update 1 Sharepoint list item from 2 different forms

Hi @diegoandre10 

In Create Item action you should assign Title to response received from MS FORM ,how you were doing earlier in create item .

 

lsajdlsaajd.JPG.png

Highlighted
Helper V
Helper V

Re: How to update 1 Sharepoint list item from 2 different forms

Hi @DeepakS 

 

I changed it and still didnt create the item:

 

asdsadsadsaasdsa.JPG

 

Could the problem be the if condition were title is equal to title?

 

Here is the test flow, the condition is grayed out:

 

dfjdsfkjdskfsjkdjkdsjf.JPG

 

Thanks again!

Highlighted
Super User II
Super User II

Re: How to update 1 Sharepoint list item from 2 different forms

Hi @diegoandre10 

 

I think i missed this, your condition should be different:

Here are steps:

- Get Items with Filter query -Title eq '<Response from FORM>'

GetItemFilter.jpg

- Add a condition action to check if Get Items returns any result:

     length(body('Get_Items')?['value']) >0
-  If True - Update item (as you already doing, and you dont need another condition there)
-  If False - Create Item (Like i suggested)
 
Let me know if this help.
 
Regards,
DS

 

View solution in original post

Highlighted
Helper V
Helper V

Re: How to update 1 Sharepoint list item from 2 different forms

Hi @DeepakS 

 

Should the get items go after or before "get response details"?


I did the title and was prompted to enter "List of response notifications response id". is the correct?

 

k1.JPG

 

Second thing is the code you gave me to be placed in the condition. Where should I type it?

 

I did it like this:

 

slaklaskd.JPG

 

Thanks for your time!

Highlighted
Community Support
Community Support

Re: How to update 1 Sharepoint list item from 2 different forms

 

Hi @diegoandre10 ,

 

You need to create two flow to update these two fields.

Both Flow structures are the same, you only need to change the Form id. When configuring Create item action and Update item action, only the specified fields need to be configured.

Spoiler
66.PNG67.PNG68.PNG

Hope this helps.

 

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

Highlighted
Helper V
Helper V

Re: How to update 1 Sharepoint list item from 2 different forms

Hi @v-bacao-msft 

 

It worked!

 

If I understand correctly, the length(body('Get_Items')?['value']) = 0 counts the items on the sharepoint list. If title is zero you create, otherwise you update.

 

Awesome!

Highlighted
Helper V
Helper V

Re: How to update 1 Sharepoint list item from 2 different forms

Thanks @DeepakS and @v-bacao-msft  for solving my problem 🙂

 

Have a great day.

Highlighted
Super User II
Super User II

Re: How to update 1 Sharepoint list item from 2 different forms

Hi @diegoandre10 

 

Good to know you fixed  it, i was actually about build your flow at my end 😉 you save my time.

 

Reagrds,

DS

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

Tech Marathon

Maratón de Soluciones de Negocio Microsoft

Una semana de contenido con +100 sesiones educativas, consultorios, +10 workshops Premium, Hackaton, EXPO, Networking Hall y mucho más!

Top Solution Authors
Top Kudoed Authors
Users online (5,901)