cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Responsive Resident
Responsive Resident

Increment variable Bug, ID Duplication in Sharepoint

Hi All,

 

Im trying use forms and flow together, when the form response has submitted the ID in excel on Splist should be updated by 1 after every new response submitted. However, i found that we can use the increment variable to acheive this, but while im trying to update the file after the response submitted, the variable is showing me same duplicate value. 

 

Please see screen shots: 

 

 

Flow1Flow1Sharepoint ListSharepoint ListFlow2Flow2

 

 

Please let me know what im i doing wrong and this has created a lot od duplication in my real data base. 

2 ACCEPTED SOLUTIONS

Accepted Solutions
Super User
Super User

@Tapesh I always have the increment number in a separate list. Then when a new response is submitted and the item is created you get the current increment value from that list, increment it by 1 using an add() expression and update the increment list so it's ready for the next item. There will only ever therefore be 1 item in that increment list.

Rob
Los Gallardos
If I've answered your question or solved your problem, please mark this question as answered. This helps others who have the same question find a solution quickly via the forum search. If you liked my response, please consider giving it a thumbs up. Thanks.

View solution in original post

Hi @Tapesh

What Rob is saying, is to have your ID (the number you want to increment by) stored somewhere on SharePoint.

The reason for this is because at this time. Your variable will always be reset every time the flow runs. The variable does not save its value from previous runs. Which is why you must store the variable somewhere so you can use the add() expression to keep adding the updated variable.




Did I answer your question? Mark my post as a solution!

If you like my post please hit the Thumbs Up


Proud to be a Flownaut!


Check out my blog for Power Automate tips, tricks, and guides
FlowAltDelete




View solution in original post

4 REPLIES 4
Super User
Super User

@Tapesh I always have the increment number in a separate list. Then when a new response is submitted and the item is created you get the current increment value from that list, increment it by 1 using an add() expression and update the increment list so it's ready for the next item. There will only ever therefore be 1 item in that increment list.

Rob
Los Gallardos
If I've answered your question or solved your problem, please mark this question as answered. This helps others who have the same question find a solution quickly via the forum search. If you liked my response, please consider giving it a thumbs up. Thanks.

View solution in original post

Responsive Resident
Responsive Resident

I m sorry i did not get you sir, what you meann to say ? 

 

@RobElliott 

can you give me the demo ? if you can please 

Responsive Resident
Responsive Resident

I tried add function not working i dont know what to do now 

Hi @Tapesh

What Rob is saying, is to have your ID (the number you want to increment by) stored somewhere on SharePoint.

The reason for this is because at this time. Your variable will always be reset every time the flow runs. The variable does not save its value from previous runs. Which is why you must store the variable somewhere so you can use the add() expression to keep adding the updated variable.




Did I answer your question? Mark my post as a solution!

If you like my post please hit the Thumbs Up


Proud to be a Flownaut!


Check out my blog for Power Automate tips, tricks, and guides
FlowAltDelete




View solution in original post

Helpful resources

Announcements
Microsoft Ignite

Microsoft Ignite

Join digitally, March 2–4, 2021 to explore new tech that's ready to implement. Experience the keynote in mixed reality through AltspaceVR!

New Super Users

Meet the Power Automate Super Users!

Many congratulations to the Season 1 2021 Flownaut Crew!

New Badges

New Solution Badges!

Check out our new profile badges recognizing authored solutions!

MPA Community Blog

Power Automate Community Blog

Check out the community blog page where you can find valuable learning material from community and product team members!

Users online (63,678)