I have a 'When an item is created or modified' flow that sends out an email based on a 'Condition' that includes a 'Status' column and the SP default 'Modified' column of an SP List.
If I use the 'Status' column only in the 'Condition' and the item Status matches the email is sent successfully.
If I add the SP default 'Modified' column to the 'Condition' and the item matches (meaning I changed an item in the moment), the flow DOES NOT send out an email.
I know 'Modified' has a time component in it. I don't care about the time, just the date.
How do I write the formula, so that 'Condition' elements match the 'Modified' elements?
What am I missing?
The 'Modified' component of the 'Condition' is -
Modified is equal to formatDateTime(utcNow(), 'MM-dd-yyyy')
Yes, I came across the 'Get changes...' action, and wondering whether this would resolve my issue.
The 'Next Date' is important, just an example.
This specific flow has branches for five branches that each look at the same 'Status' column, with 'Status' options -
'Under Review', 'Agenda Pending', 'Minutes Pending', etc.
The Status change can be trigged by a formula in the Power App or another (recurring flow).
Each of the branches has its own 'Condition'. If item one Status is 'Under Review' and item two Status is 'Agenda Pending', and if Power Apps or another flow changes the Status of item two to 'Under Review', the flow should send an email ONLY specific to the change item (item 2), as there was no change to item 1, which was already 'Under Review' and had no change.
@Phineas I need more clarity on your logic.
What conditions need to be met to send an email besides the status being Under Review? Is there a specific column you are looking for a change in? If so, you'll need to add a Get changes for an item or file (properties only) action.
What's the significance of the Next Date column? Does this flow send out a single email only (per item) when conditions are met? Or does your flow send out multiple emails per item based on the changes?
It would also help to see what your flow looks like currently.
I am familiar with the flow trigger/condition protocols.
What I am unclear on is whether the flow will continue to send out the same email for the same item - 'Status' of the Status remains 'Under Review' even if the reason for the flow trigger was not a change to that specific item?
Example:
The list has a Status column. The list has a 'Next Date' column.
The flow has several branches, including one for 'Status' and one for 'Next Date'.
The flow will trigger any time an item is created or updated in the list.
Does the flow send an email only the for the item changed, if it meets the condition of that branch, or does it repeatedly send emails out for all branches where an item meets the condition?
User 1 accesses the data through Power Apps and changes a date column and sends it on to the SP List.
There is branch that says if the date is changed send out a email.
This action triggers the flow, and an email goes out to a member that says the date has been updated.
On the same list is a different item with the 'Status' "Under Review". There is a branch in the flow with a 'Condition' that says if the Status equals 'Under Review' send out an email. However, the item with the Status 'Under Review' was not the item changed. In this case I don't want an email send merely because the condition is met.
The email should only go out if the item changed meets the condition, not all items on the list that meet a branch condition by default.
In the example the change was not to the 'Under Review' item. An email notification had previously been sent regarding this item when it was changed.
I do not want another email to be sent on that item merely because the date was changed on another.
@Phineas Since you are using the When an item is created or modified trigger. I would recommend using Trigger conditions instead.
Set up your trigger condition so that the flow only triggers when:
In this case you don't need a condition to check when the item was modified, this assuming you only want to trigger this particular flow when the Status is equal to Under Review.
Check out this YT Tutorial for more details on how to add Trigger Conditions to your flow: 4 Ways You Can Use Trigger Conditions in Your Microsoft Power Automate Flow
If you are using an Automated Cloud flow trigger in your flow—you need to consider adding trigger conditions.
Do YOU 🫵 know what a trigger condition is? Trigger conditions can be set in most flow triggers. These conditions you set must be true for the trigger to fire. In this Power Automate tutorial, I’m going to show you how to use trigger conditions in your flows to control when your Power Automate flows trigger.
If your plan has flow run limits—you can avoid triggering your flows unnecessarily by using trigger conditions.
I’ll cover four different flow examples that would benefit from trigger conditions:
⚡️ Triggering a flow when a column is changed to a specific value
⚡️ Triggering a Flow When an Event Updated or Deleted
⚡️ Triggering a Flow When a New Folder is Created
⚡️ Triggering a Flow When a Specific Email is Received I’ll also show you a trick on how to easily create the expressions needed and give you a few tips on how to troubleshoot your flow.
IN THIS VIDEO:
âś… Four different flows that would benefit from trigger conditions
âś… What is a trigger condition?
âś… How to add a trigger condition to your flow
âś… How to trigger a flow when a column is changed to a specific value
âś… How to trigger a flow when an event is updated or Deleted
âś… How to trigger a flow when a new folder is created
âś… How to trigger a flow when a specific email is received
âś… How to troubleshoot a trigger condition
âś… How to prevent case sensitivity issues with a trigger condition
âś… How to use the filter array action to easily compose an expression that can be used in a trigger condition
I understand your instruction, but I don't think it will solve my problem.
I don't want the email to go out based on the time of day, necessarily.
I want the email to go out at the time the item is changed, but not go out again every time another item is created or edited in the list - the trigger is 'When an item is created or modified'.
I have multiple branches. For this branch the 'Status' must equal 'Under Review'. If I use only this in the 'Condition', every time an item is created or the list is changed the email will go out again and again - if the Status is still 'Under Review', yes?
This is what I am trying to prevent. The email should go out once, based on the 'Status', but not again if another item is added or changed.
Is this possible?
@Phineas Because the Modified column is a timestamp you need a filter query that considers the time. Your original filter query will never equal true because you haven't considered the time (also, you need to use eq as the operator).
Modified is equal to formatDateTime(utcNow(), 'MM-dd-yyyy')
You can either use a Filter Array action to filter out the items where the date matches. Refer to this YT tutorial:
Send Emails Based on a 📆 Date Column in SharePoint with Microsoft Power Automate
In this Microsoft Power Automate tutorial, I’ll show you how to build a flow that will send a Happy Birthday email to a user based on a date column in a SharePoint list. The SharePoint list also contains a column with a Manager’s name which we’ll use to send a three-day and day of reminder to the user’s manager.
This automation will use the Filter Array action to filter out all SharePoint list items where the user’s birthday is today or in three days. This flow can apply to a variety of scenarios such as:
đź“… Student Birthdays
đź“… Project Due Dates
đź“… Contract/Membership Renewals
đź“… License Expirations
đź“… Client Anniversaries
IN THIS VIDEO:
âś… How to Send an Email based on a Date Column in SharePoint
âś… Using the Recurrence Trigger in Power Automate
âś…How to Use the Filter Array Action with multiple conditions
âś… How to Get Dynamic Content from a Filter Array Action
âś…How to Get a Date Three Days from Today
âś… How to Create a Dynamic Date Based on utcNow()
âś… How to Return a Count of Items
âś… How to initialize and set a variable
âś… How to use the Send an Email (V2) action
âś… How to send test emails
----
Alternatively, you need to adjust your filter query to include a time:
Modified gt formatDateTime(utcNow(), 'yyyy-MM-ddT00:00:00') and Modified le formatDateTime(utcNow(), 'yyyy-MM-ddT23:59:00')
Specifically, you need to the filter query to check for the items with a modified date greater than (gt) 12am and less than (lt) 11:59 pm.
WarrenBelz
146,765
Most Valuable Professional
RandyHayes
76,287
Super User 2024 Season 1
Pstork1
66,091
Most Valuable Professional