cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
CWilcox
Advocate I
Advocate I

SharePoint list item field updated

It would be good if we could set a 'Flow' to only work when the value of a field changes.

 

Example:

 

We have a 'column' with 3 possible options 1) Planning, 2) Promote, 3) Finished.

 

When a new item is created by default the column is set to 'Planning'.

 

Although many other changes may occur in other columns, we would only want the 'Flow' to start when this particular column is changed. But when other columns are changed no 'Flow' is triggered.

 

Hope this is something that could be implemented, as the current 'Flows' will run each time any column is updated.

1 ACCEPTED SOLUTION

Accepted Solutions

If you use the Sharepoint Connector Trigger for When a Sharepoint item is created or modified and then a Switch case switchflow.PNG

You can accomplish this already. This will run everytime something is added or changed but it won't take any actions unless you define it to. 

View solution in original post

41 REPLIES 41
PLN
Advocate I
Advocate I

Today a trigger is generated if any field in a list is updated. This is not enough to generate effective workflows on sharepoint list. The sugegstion is to give the option of specify the Field of the list on to be considered to generate the trigger ...

Thanks

 

When trying to build a workflow around a particular field in a SharePoint list, we have to use the "When an existing item is modified" condition and a check against a hidden "previous value" column. If the column and the previous value column differ, then do action. This gets more and more cumbersome with each additional column/flow. Instead, I'd like a condition that checks for a specific field being updated.

For example:

If I want to do a different event depending on the new value of the Status column, I have to write a flow like:

CONDITION: When an existing item is modified >
CONDITION: If Status does not equal Status (previous) >

CONDITION: If Status equals "Pending"

    ACTION: Email Approvers

    ELSE CONDITION: If Status equals "Approved"

        ACTION: Email Submitters

        ELSE CONDITION: If Status equals "Rejected"

            ACTION: Email Submitters

ACTION: Update Status (previous), set to Status

 

 

What I'd prefer is:

 

If I want to do a different event depending on the new value of the Status column, I have to write a flow like:

CONDITION: When a specific field is modified >

CONDITION: If Status equals "Pending"

    ACTION: Email Approvers

    ELSE CONDITION: If Status equals "Approved"

        ACTION: Email Submitters

        ELSE CONDITION: If Status equals "Rejected"

            ACTION: Email Submitters

Anonymous
Not applicable

I agree with this. It should be easy to add an IF statement for the flow to only look for changes in a specific column. For example, I only need to receive an email when an item in an Open Issues List has been changed from open to close. Simple!!

If you use the Sharepoint Connector Trigger for When a Sharepoint item is created or modified and then a Switch case switchflow.PNG

You can accomplish this already. This will run everytime something is added or changed but it won't take any actions unless you define it to. 

CWilcox
Advocate I
Advocate I

 Hi MWilliams86,

 

Thanks for that, that sounds brilliant.

 

Thank you for the assistance.

Anonymous
Not applicable

@MWilliams86 indeed, but it does cost you extra runs...

The suggested solution is great if you know the possible values for a field - but what if you want to do something only if the text in a field has changed, for example? Right now the only work around I've seen suggested is to store the "original" value in its own column so you can compare the old vs. the new value and take action, and then update the tracking column with the new value so they match again..... Feels awfully clunky.

Pandra
Advocate II
Advocate II

MWilliams86, thanks for the above suggestion. 

 

Interesting approach indeed. My case is a little different and this would not work:

 

I have an Onboarding list, and need to notifiy the next department when the current department updates the record. All departments indicate their completion by checking a separate Y/N box for their department - that's the trigger I need, simply when a value changes on a specific field. All of my "complete" fields are Y/N, so the Switch Case example would not work here, because all of the values I'm looking for are "Y" or "Yes"

 

Flow Team - we do need a new trigger based soley on when a value changes. That would make a lot of people very productive with this, and very happy. It's already part of the ..."when created or updated" trigger - a modified version of that would be great. Make it so! 🙂

 

 

 

 

 

Hey Pandara,

 

You can accomplish your sceanario with a serires of nested Condition steps. 

 

When an item is created or modified -> Condition: IF department 1 checkfield IsBlank() -> Yes condition send email to department 1 for approval -> No condition: New Condition: IF department 1 checkfield = "y" or "yes" AND department 2 checkfield IsBlank(), ....

 

And keeping nesting for however meany departments you need with each department having its own checkfield for the Condition IF statements to check for. 

 

At least that's how I'd approach that scenario until different functionality is created in Flow. Smiley Happy

Pandra
Advocate II
Advocate II

 

 

 

 

mab17
Frequent Visitor

I'm creating a flow for a QC process that involves 5 different employees in our office.  As an item in a Sharepoint list gets modified, and when a Yes/No column in my list is changed from "no" to "yes", I've set up a condition for my flow to send an email to the next employee needing to work the QC process.  Unfortunately, the flow keeps dupicating emails to the first member of the QC process.  I'm struggling to figure out how to modify the flow so repeating emails are no longer generated to the initial first members of the QC process. Any suggestions would be greatly appreciated!

Flow issue.PNG

Anonymous
Not applicable

@mab17you could create an array (via compose action) where you store all the names of the persons already received an e-mail, and check this array before sending the next e-mails in line.

 

At least that's how I could tackle this one 😉

mab17
Frequent Visitor

@Anonymous Thanks for your reply.  I like your idea, however I'm still a little confused as to how to create an array.  I've searched for info but am new enough to FLOW not all instructions are helpful.  Any further direction would be greatly appreciated.

 

Anonymous
Not applicable

You will probably need the compose action to accomplish this.

See post below for some more information: https://powerusers.microsoft.com/t5/Building-Flows/create-array-in-apply-each/td-p/62719

Further to this, by triggering on every change, we consume our allowance in a couple days. Need to be able to create an environment where the flow only coumnts when it actually does something. I set hidden fields, but flow still fires and counts against quote. Worse is that if the flow changes a column then it fires again so I pay for two flows every time I update a filed.... be awesome to run only when a specific field changes.    Use Nintex as a role model on this where they add a conditional section before th flow starts....   like start if this field ahances AND ... so we can create complex rules to determine if the flow even runs.      

I don't understand how this is marked as complete. I tried the solution and it obviously does not do what the original question wants.

 

If I want to do something when the status changes from A to B, if it so happens that the original status is A, and they make a modification to B, then the flow runs. Then, if someone changes another field, but the status is still B, then the flow runs again. That's not right. It should only run when the status is updated, not when "anything" is modified and the status remains B.

I searched and found a blog post that solves this issue using a combination of List Versioning and an HTTP Request.

 

SharePoint Trigger on specific fields changed via SP HTTP Request

 

http://johnliu.net/blog/2018/5/microsoft-flow-sharepoint-trigger-on-specific-fields-changed-via-sp-h...

 

I had to enable Item Version History in the list settings.  Then I added an action "SharePoint - Send an HTTP Request to SharePoint" and have it GET this Uri on my SharePoint site -

_api/web/lists/getbytitle('ListName')/items(10)/versions?$top=2

 

Last, I added a Select action to filter the output into an array -

body('SPREST-Versions')?['value']

and used a Condition to test if the new value is equal to the old value,

first(body('SelectVersions'))?['Title'] is equal to last(body('SelectVersions'))?['Title']

Read blog post for details.

I have an approval process for list items and I wanted to send an approval email only when the status of the item changed from "Ordered" to "Ready".

 

The change of the status "Ordered" to "Ready" is an automized process so I though I would just put a "Wait until" or "Wait" function but this was not possible as the wait time is not always the same. I wanted to send an approval email from the moment it's ready so I have searched for a solution where there would be a check on a specific field. 

 

I tried using switch case or condition but there was a problem when other fields were updated and the condition was already fulfilled, it would send again an approval email:
eg item changed - Status is not "Ready" = Terminate (that's OK)
item changed - Status is "Ready" = send approval email (that's correct) but now item is changed again, other field is updated and the status is still "Ready" = approval email resent (that's not correct as it does not check what was updated" 

 

I did not want to use nested conditions or switch cases.

The solution link provided by @grahampasmurf with version checking did the trick!! http://johnliu.net/blog/2018/5/microsoft-flow-sharepoint-trigger-on-specific-fields-changed-via-sp-h...

 

Thank you for that!

 

It did require some adaptation but it works!

 

flowemail1.PNGflowemail2.PNG

- ID can be found in "See more" Dynamic content

- SPREST-Versions is just renamed "Send HTTP request to Sharepoint"

- In the Url, if you use space or other special chars, you need to pay attention to how it's written eg space = %20

- Value is the expression from the linked website Body('SPREST-Versions')?['value']

- Orderstatus = valuefield "ValoTeamwork" is not found via Dynamic content but via Output from "Select" When I used the Dynamic content value it did not work as "Valo Teamwork" contained the actual value and was passing it throung to "GroupSiteUrl" from Dynamic content which remaind always the same.

- HTML table is not needed but usefull to debug and make sure it works correctly

- Conditions can again be found on the linked website: first(body('Select'))?['Orderstatus'] - last(body('Select'))?['Orderstatus']

 

More about approval flow

https://powerusers.microsoft.com/t5/Using-Flows/Flow-and-SharePoint-List-Status/m-p/132299#M3532

 

 

Hope this helps!

 

sarah5
Advocate I
Advocate I

This is insane! There needs to be an easier solution for a highly requested feature. Not all of us who use microsoft flow know how to create complex coding like the solution offered here (which seems great so thank you, it helped) - http://johnliu.net/blog/2018/5/microsoft-flow-sharepoint-trigger-on-specific-fields-changed-via-sp-h...

 

There needs to be an automatic trigger where we can select via the dynamic content list to identify fields we want to be notified of any changes! 

Helpful resources

Announcements

Community will be READ ONLY July 16th, 5p PDT -July 22nd

Dear Community Members,   We'd like to let you know of an upcoming change to the community platform: starting July 16th, the platform will transition to a READ ONLY mode until July 22nd.   During this period, members will not be able to Kudo, Comment, or Reply to any posts.   On July 22nd, please be on the lookout for a message sent to the email address registered on your community profile. This email is crucial as it will contain your unique code and link to register for the new platform encompassing all of the communities.   What to Expect in the New Community: A more unified experience where all products, including Power Apps, Power Automate, Copilot Studio, and Power Pages, will be accessible from one community.Community Blogs that you can syndicate and link to for automatic updates. We appreciate your understanding and cooperation during this transition. Stay tuned for the exciting new features and a seamless community experience ahead!

Summer of Solutions | Week 4 Results | Winners will be posted on July 24th

We are excited to announce the Summer of Solutions Challenge!    This challenge is kicking off on Monday, June 17th and will run for (4) weeks.  The challenge is open to all Power Platform (Power Apps, Power Automate, Copilot Studio & Power Pages) community members. We invite you to participate in a quest to provide solutions to as many questions as you can. Answers can be provided in all the communities.    Entry Period: This Challenge will consist of four weekly Entry Periods as follows (each an “Entry Period”)   - 12:00 a.m. PT on June 17, 2024 – 11:59 p.m. PT on June 23, 2024 - 12:00 a.m. PT on June 24, 2024 – 11:59 p.m. PT on June 30, 2024 - 12:00 a.m. PT on July 1, 2024 – 11:59 p.m. PT on July 7, 2024 - 12:00 a.m. PT on July 8, 2024 – 11:59 p.m. PT on July 14, 2024   Entries will be eligible for the Entry Period in which they are received and will not carryover to subsequent weekly entry periods.  You must enter into each weekly Entry Period separately.   How to Enter: We invite you to participate in a quest to provide "Accepted Solutions" to as many questions as you can. Answers can be provided in all the communities. Users must provide a solution which can be an “Accepted Solution” in the Forums in all of the communities and there are no limits to the number of “Accepted Solutions” that a member can provide for entries in this challenge, but each entry must be substantially unique and different.    Winner Selection and Prizes: At the end of each week, we will list the top ten (10) Community users which will consist of: 5 Community Members & 5 Super Users and they will advance to the final drawing. We will post each week in the News & Announcements the top 10 Solution providers.  At the end of the challenge, we will add all of the top 10 weekly names and enter them into a random drawing.  Then we will randomly select ten (10) winners (5 Community Members & 5 Super Users) from among all eligible entrants received across all weekly Entry Periods to receive the prize listed below. If a winner declines, we will draw again at random for the next winner.  A user will only be able to win once overall. If they are drawn multiple times, another user will be drawn at random.  Individuals will be contacted before the announcement with the opportunity to claim or deny the prize.  Once all of the winners have been notified, we will post in the News & Announcements of each community with the list of winners.   Each winner will receive one (1) Pass to the Power Platform Conference in Las Vegas, Sep. 18-20, 2024 ($1800 value). NOTE: Prize is for conference attendance only and any other costs such as airfare, lodging, transportation, and food are the sole responsibility of the winner. Tickets are not transferable to any other party or to next year’s event.   ** PLEASE SEE THE ATTACHED RULES for this CHALLENGE**   Week 1 Results: Congratulations to the Week 1 qualifiers, you are being entered in the random drawing that will take place at the end of the challenge.   Community MembersNumber SolutionsSuper UsersNumber Solutions Deenuji 9 @NathanAlvares24  17 @Anil_g  7 @ManishSolanki  13 @eetuRobo  5 @David_MA  10 @VishnuReddy1997  5 @SpongYe  9JhonatanOB19932 (tie) @Nived_Nambiar  8 @maltie  2 (tie)   @PA-Noob  2 (tie)   @LukeMcG  2 (tie)   @tgut03  2 (tie)       Week 2 Results: Congratulations to the Week 2 qualifiers, you are being entered in the random drawing that will take place at the end of the challenge. Week 2: Community MembersSolutionsSuper UsersSolutionsPower Automate  @Deenuji  12@ManishSolanki 19 @Anil_g  10 @NathanAlvares24  17 @VishnuReddy1997  6 @Expiscornovus  10 @Tjan  5 @Nived_Nambiar  10 @eetuRobo  3 @SudeepGhatakNZ 8     Week 3 Results: Congratulations to the Week 3 qualifiers, you are being entered in the random drawing that will take place at the end of the challenge. Week 3:Community MembersSolutionsSuper UsersSolutionsPower Automate Deenuji32ManishSolanki55VishnuReddy199724NathanAlvares2444Anil_g22SudeepGhatakNZ40eetuRobo18Nived_Nambiar28Tjan8David_MA22   Week 4 Results: Congratulations to the Week 4 qualifiers, you are being entered in the random drawing that will take place at the end of the challenge. Week 4:Community MembersSolutionsSuper UsersSolutionsPower Automate Deenuji11FLMike31Sayan11ManishSolanki16VishnuReddy199710creativeopinion14Akshansh-Sharma3SudeepGhatakNZ7claudiovc2CFernandes5 misc2Nived_Nambiar5 Usernametwice232rzaneti5 eetuRobo2   Anil_g2   SharonS2  

Check Out | 2024 Release Wave 2 Plans for Microsoft Dynamics 365 and Microsoft Power Platform

On July 16, 2024, we published the 2024 release wave 2 plans for Microsoft Dynamics 365 and Microsoft Power Platform. These plans are a compilation of the new capabilities planned to be released between October 2024 to March 2025. This release introduces a wealth of new features designed to enhance customer understanding and improve overall user experience, showcasing our dedication to driving digital transformation for our customers and partners.    The upcoming wave is centered around utilizing advanced AI and Microsoft Copilot technologies to enhance user productivity and streamline operations across diverse business applications. These enhancements include intelligent automation, AI-powered insights, and immersive user experiences that are designed to break down barriers between data, insights, and individuals. Watch a summary of the release highlights.    Discover the latest features that empower organizations to operate more efficiently and adaptively. From AI-driven sales insights and customer service enhancements to predictive analytics in supply chain management and autonomous financial processes, the new capabilities enable businesses to proactively address challenges and capitalize on opportunities.    

Updates to Transitions in the Power Platform Communities

We're embarking on a journey to enhance your experience by transitioning to a new community platform. Our team has been diligently working to create a fresh community site, leveraging the very Dynamics 365 and Power Platform tools our community advocates for.  We started this journey with transitioning Copilot Studio forums and blogs in June. The move marks the beginning of a new chapter, and we're eager for you to be a part of it. The rest of the Power Platform product sites will be moving over this summer.   Stay tuned for more updates as we get closer to the launch. We can't wait to welcome you to our new community space, designed with you in mind. Let's connect, learn, and grow together.   Here's to new beginnings and endless possibilities!   If you have any questions, observations or concerns throughout this process please go to https://aka.ms/PPCommSupport.   To stay up to date on the latest details of this migration and other important Community updates subscribe to our News and Announcements forums: Copilot Studio, Power Apps, Power Automate, Power Pages

Users online (725)