How to stop infinite loop of MS Flow when SharePoint item modified

Recently I was developing a workflow using MS flow for my client. The basic requirement was to update SharePoint list. During development I was surprised because workflow was not stopping when updating a list item. It was getting into infinite loop. Then after lot of investigation I found that whenever updating an item the MS Flow ‘When an item is created or modified’ trigger again and it’s become never ending. Now the question is it possible to stop? Yes.

Let’s discuss the solution in details.

Step 1: Create a list and name it ‘FlowTest’ with column ‘Country’ and ‘First Letter’. Country is a drop-down column with values — Brazil, India, USA.

Step 2 : Now Create a MS flow with same name as list name. The logic of the MS flow is when Country field value is ‘Brazil’ the flow will update ‘First Letter’ field value to ‘B’ otherwise ‘Unknown’.


Originally published at indianjackofalltrade.com on September 9, 2018.

Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch
Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore
Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade