cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Trigger flow when only one field in list is modified

Hello - I have a flow that triggers an automated email when a list field, "Status" changes from 'Open' to closed. However, the email triggers whenever any field is changed. Is there a way to fine tune so that this will only trigger on the desired field and no other field?

 

 inkedFlow.jpg

1 ACCEPTED SOLUTION

Accepted Solutions
v-yuazh-msft
Community Support
Community Support

Hi @Anonymous,

 

As @ScottShearer said, there is no any trigger on a special column in list is modified,if you would like to trigger a flow when a special column in list is modified,

I afraid that there is no way to achieve your needs in Microsoft Flow currently.

 

If you would like this feature to be added in Microsoft Flow, please submit an idea to Flow Ideas Forum:

https://powerusers.microsoft.com/t5/Flow-Ideas/idb-p/FlowIdeas

 

You could take the alternative way offered by @ScottShearer, however, the alternative way wouldn't work when the field value in the list is modified several times.

I have another alternative way, you could also take a try with mine.

1. Add a yes/no type column "Status is changed" in the sharepoint list.

2.Every time a user modify the list, if he have modify the "Status" column,he must modify the "Status is changed" column to "Yes", 

if he haven't modify the "Status" column,he must keep the  "Status is changed" column to "No".

3.You could add an condition under the trigger to check if the "Status is changed" column is equal to true or false.if the "Status is changed"column is equal to true,send the email,if the  the "Status is changed" column is equal to false,do nothing.

 

 

Best regards,

Alice

View solution in original post

28 REPLIES 28
ScottShearer
Super User
Super User

The short answer is no, you can't  have a Flow trigger only when a specified column is changed,

 

The simple work around is to store a copy of the column data in a separate column.  When the Flow is triggered, compare the two columns.  If they are the same, do nothing,  If they are not the same, take action as appropriate and update the additional column to match the value in the column you are monitoring.

 

There are other more elegant solutions, but what I have presented is the quick and simple fix.

 

Scott

If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Scott
v-yuazh-msft
Community Support
Community Support

Hi @Anonymous,

 

As @ScottShearer said, there is no any trigger on a special column in list is modified,if you would like to trigger a flow when a special column in list is modified,

I afraid that there is no way to achieve your needs in Microsoft Flow currently.

 

If you would like this feature to be added in Microsoft Flow, please submit an idea to Flow Ideas Forum:

https://powerusers.microsoft.com/t5/Flow-Ideas/idb-p/FlowIdeas

 

You could take the alternative way offered by @ScottShearer, however, the alternative way wouldn't work when the field value in the list is modified several times.

I have another alternative way, you could also take a try with mine.

1. Add a yes/no type column "Status is changed" in the sharepoint list.

2.Every time a user modify the list, if he have modify the "Status" column,he must modify the "Status is changed" column to "Yes", 

if he haven't modify the "Status" column,he must keep the  "Status is changed" column to "No".

3.You could add an condition under the trigger to check if the "Status is changed" column is equal to true or false.if the "Status is changed"column is equal to true,send the email,if the  the "Status is changed" column is equal to false,do nothing.

 

 

Best regards,

Alice

Anonymous
Not applicable

Hello,

 

I know how old this is but I have a question that is related to this one. When trying to trigger a flow based off the value of a specific column using a condition is there a way for it to recognize string values?

 

Like if you want an email sent only when Column A reads "send email" is there a way to do this? I tried to use one of my columns in a condition and for flow to check if a specific string was selected but it never works.

Anonymous
Not applicable

I hate to comment on a stale thread; but I have found a way to trigger an approval flow based on a field value.

 

It looks like everyone has some kind of status field that needs to be evaluated (it's really how I started). After following the information posted at the beginning of the thread; I tested and received the expected result of failure.

 

However, if you initialize a variable and pull that field value into it (Initialize variable, then set variable to field value; in my instance the second step for setting was to use 'status value'). Once that is pulled into a variable the statement can be evaluated with the condition statement. I've tested on several different tables within my instance of SharePoint and it's pretty effective every time.

Anonymous
Not applicable

@Anonymous , can you post a screen shot of the solution?

Anonymous
Not applicable

I can't do the image attachment (DLP Policies for my organization). But I can do the JSON code:

 

 

"Initialize_variable_-_StatusField": {
							"runAfter": {
								"Initialize_variable_-_EmailString": ["Succeeded"]
							},
							"type": "InitializeVariable",
							"inputs": {
								"variables": [{
										"name": "StatusField",
										"type": "String"
									}
								]
							}
						},
						"Set_variable_-_StatusField": {
							"runAfter": {
								"Initialize_variable_-_StatusField": ["Succeeded"]
							},
							"type": "SetVariable",
							"inputs": {
								"name": "StatusField",
								"value": "@triggerBody()?['Status']?['Value']"
							}
						}

 

Anonymous
Not applicable

@Anonymous I think the problem with your code is that if any other column's value changes and if your Status column has a value in it (whether its the same or changed status), it will trigger the flow as well.

Anonymous
Not applicable

Correct; it will trigger for any modification; but will only proceed if the status field is equal to something I've configured to run.

 

I've done this on a few flows and it works fairly flawlessly.

Any changes to PowerAutomate on this issue? In the last 6 months, there have been massive strides in updates to PowerApps but wasn't sure about Automate. 

I don't know if this has been covered in a different forum item or not but I use a Switch in these scenarios. The trigger is the same as in the original post (item in list is modified), and next I add the Switch and specify the Status column using Dynamic Content. This then gives you the ability to add Cases, and here you use the Status options from your column (manually typed in not selectable as dynamic content so watch out for spelling!). You can then build out the rest of your flow with email notifications etc as you would with a condition. It works really well for status columns with multiple options (max I've used is 8 so far) sending notifications to different people in a process when the status value changes each with a customised message. Hopefully this helps

Yes! I switched to using "switch" back in August and have used it exclusively. Works so much better than the condition. Thanks!

Sorry!! I know this is an old thread, but can you step me through this?

What is a switch? Sorry! am very new to SP

 

Thanks,

Ashlea

anilrambhajan
Helper III
Helper III

Any solution for this? Help

So yeah this is old, but I have a situation where if a status is changed, I need to send an email.  How I did it was having a second "former status" field.  That way, when an item is changed, I can compare the statuses to see if that is the field changed.  If the statuses are different, send that email and change the "former status" to the same as the status.  If they are the same, then obviously something else was changed and nothing needs to happen.

Thank you for your response. Yes, I ended up doing something very similar. I used a boolen column and set it to true if the column value changes and use that column as my trigger.

Antiwa
Regular Visitor

Well there is a simple way to specify a trigger condition to your flow when a specific field data changes to a specific value. In your case when 'Status' field value changes to 'Close'.

1. Go to setting of the 'when an item is created or modified' connector using '...' option.

2. Configure the trigger condition of the flow.

Here is the snip of the expression:trigger .jpg

 

You are right, however this is assuming the use case is to only determine when the status is closed.

Consider you have a status column with let's say 8 different statuses and you would like to determine each time the status column gets updated to do whatever you need to do.

With your suggested approach, that would be 8 different flows each with a trigger for the specific status. Not really practical and maintainable for such use case.

I honestly would choose a choice, rather than a boolean and use case to determine the action.  This then requires only one flow.  An annoying one to look at on the screen, but it'll work.

Anonymous
Not applicable

Since the original question was to only trigger when a specific column changes, the solution would be to have a second column that stores the "former status" value.  Make the trigger contrition when the Status column is not equal to the former status column.  

When the flow runs, update the "former status" column to the current status.   They are now equal and the flow will not trigger again until the status is changed.  This will work for any number of potential Status values.

Helpful resources

Announcements

Power Platform Connections - Episode 7 | March 30, 2023

Episode Seven of Power Platform Connections sees David Warner and Hugo Bernier talk to Dian Taylor, alongside the latest news, product reviews, and community blogs.     Use the hashtag #PowerPlatformConnects on social media for a chance to have your work featured on the show.  

Announcing | Super Users - 2023 Season 1

Super Users – 2023 Season 1    We are excited to kick off the Power Users Super User Program for 2023 - Season 1.  The Power Platform Super Users have done an amazing job in keeping the Power Platform communities helpful, accurate and responsive. We would like to send these amazing folks a big THANK YOU for their efforts.      Super User Season 1 | Contributions July 1, 2022 – December 31, 2022  Super User Season 2 | Contributions January 1, 2023 – June 30, 2023    Curious what a Super User is? Super Users are especially active community members who are eager to help others with their community questions. There are 2 Super User seasons in a year, and we monitor the community for new potential Super Users at the end of each season. Super Users are recognized in the community with both a rank name and icon next to their username, and a seasonal badge on their profile.  Power Apps  Power Automate  Power Virtual Agents  Power Pages  Pstork1*  Pstork1*  Pstork1*  OliverRodrigues  BCBuizer  Expiscornovus*  Expiscornovus*  ragavanrajan  AhmedSalih  grantjenkins  renatoromao    Mira_Ghaly*  Mira_Ghaly*      Sundeep_Malik*  Sundeep_Malik*      SudeepGhatakNZ*  SudeepGhatakNZ*      StretchFredrik*  StretchFredrik*      365-Assist*  365-Assist*      cha_cha  ekarim2020      timl  Hardesh15      iAm_ManCat  annajhaveri      SebS  Rhiassuring      LaurensM  abm      TheRobRush  Ankesh_49      WiZey  lbendlin      Nogueira1306  Kaif_Siddique      victorcp  RobElliott      dpoggemann  srduval      SBax  CFernandes      Roverandom  schwibach      Akser  CraigStewart      PowerRanger  MichaelAnnis      subsguts  David_MA      EricRegnier  edgonzales      zmansuri  GeorgiosG      ChrisPiasecki  ryule      AmDev  fchopo      phipps0218  tom_riha      theapurva  takolota     Akash17  momlo     BCLS776  Shuvam-rpa     rampprakash  ScottShearer     Rusk  ChristianAbata     cchannon  Koen5     a33ik  Heartholme     AaronKnox  okeks      Matren   David_MA     Alex_10        Jeff_Thorpe        poweractivate        Ramole        DianaBirkelbach        DavidZoon        AJ_Z        PriyankaGeethik        BrianS        StalinPonnusamy        HamidBee        CNT        Anonymous_Hippo        Anchov        KeithAtherton        alaabitar        Tolu_Victor        KRider        sperry1625        IPC_ahaas      zuurg    rubin_boer   cwebb365   Dorrinda   G1124   Gabibalaban   Manan-Malhotra   jcfDaniel   WarrenBelz   Waegemma   drrickryp   GuidoPreite    If an * is at the end of a user's name this means they are a Multi Super User, in more than one community. Please note this is not the final list, as we are pending a few acceptances.  Once they are received the list will be updated. 

Register now for the Business Applications Launch Event | Tuesday, April 4, 2023

Join us for an in-depth look into the latest updates across Microsoft Dynamics 365 and Microsoft Power Platform that are helping businesses overcome their biggest challenges today.   Find out about new features, capabilities, and best practices for connecting data to deliver exceptional customer experiences, collaborating, and creating using AI-powered capabilities, driving productivity with automation—and building towards future growth with today’s leading technology.   Microsoft leaders and experts will guide you through the full 2023 release wave 1 and how these advancements will help you: Expand visibility, reduce time, and enhance creativity in your departments and teams with unified, AI-powered capabilities.Empower your employees to focus on revenue-generating tasks while automating repetitive tasks.Connect people, data, and processes across your organization with modern collaboration tools.Innovate without limits using the latest in low-code development, including new GPT-powered capabilities.    Click Here to Register Today!    

Check out the new Power Platform Communities Front Door Experience!

We are excited to share the ‘Power Platform Communities Front Door’ experience with you!   Front Door brings together content from all the Power Platform communities into a single place for our community members, customers and low-code, no-code enthusiasts to learn, share and engage with peers, advocates, community program managers and our product team members. There are a host of features and new capabilities now available on Power Platform Communities Front Door to make content more discoverable for all power product community users which includes ForumsUser GroupsEventsCommunity highlightsCommunity by numbersLinks to all communities Users can see top discussions from across all the Power Platform communities and easily navigate to the latest or trending posts for further interaction. Additionally, they can filter to individual products as well.   Users can filter and browse the user group events from all power platform products with feature parity to existing community user group experience and added filtering capabilities.     Users can now explore user groups on the Power Platform Front Door landing page with capability to view all products in Power Platform.      Explore Power Platform Communities Front Door today. Visit Power Platform Community Front door to easily navigate to the different product communities, view a roll up of user groups, events and forums.

Microsoft Power Platform Conference | Registration Open | Oct. 3-5 2023

We are so excited to see you for the Microsoft Power Platform Conference in Las Vegas October 3-5 2023! But first, let's take a look back at some fun moments and the best community in tech from MPPC 2022 in Orlando, Florida.   Featuring guest speakers such as Charles Lamanna, Heather Cook, Julie Strauss, Nirav Shah, Ryan Cunningham, Sangya Singh, Stephen Siciliano, Hugo Bernier and many more.   Register today: https://www.powerplatformconf.com/   

Users online (3,898)