I have a SharePoint list that is populated from SQL on a scheduled task. I was to be able to use this list as a location where users can access to make requests to update data that then copies over to another SharePoint list for review by an SME. The issue I'm having is the flow I'm using (When an Item is created or modified) is copying and emailing me everytime my SQL to SharePoint task runs. I only want the data to copy and notify me when the data is modified by a user. Any help as to how I can do this?
You probably need to add a 'Condition' action block, evaluate whatever condition you need, on the true branch add email notification, leave false branch empty
'notify me when the data is modified by a user'
A specific user, you mean?
On the left part of you condition you shall add the following expression
On the right side just type its email address
Please note in order to add expressions you need to follow these steps
Please implement suggested approach, if problem persis or flow execution fails please share a screenshot from Flow design
I went ahead and added the expression and(triggerBody()?['Modified'],not(equals(triggerbody()['Created']))) to both of the columns that I want. When either of the two of these columns are modified (columns are choice), an email notification should be sent and the data with any attachments should be sent to my other list. If the data is being replaced/created during the scheduled task from SQL, the notification email should not be sent and the data should not be copied.
The users modifying this list is not just one person. It could be anyone from my department.
The suggestion you made didn't fail but it didn't copy the data to my other list and it didn't send an email notification. Below you will find the skip message I received.
"I went ahead and added the expression and(triggerBody()?['Modified'],not(equals(triggerbody()['Created']))) to both of the columns that I want. When either of the two of these columns are modified (columns are choice), an email notification should be sent and the data with any attachments should be sent to my other list"
Probably it's me who is not understanding properly your approach... It sounds to me as a wrong one. First of all, 'Modified', 'Created' relates to the whole item, no to particular columns. So, if you create an item then modify any column value, Modified will no longer equal to Created.
Also the expression
does not make sense. equals() needs two entries, you only added one
Now, on the issue described at the beginning of this thread:
"I only want the data to copy and notify me when the data is modified by a user."
What I understood is that you wanted copy+notify when data is modified by a specific user (let's say firstname.lastname@example.org). THat's why I suggested to evaluate a condition like:
When using a Condition action block, things are done in a more visual way, so you just add first entry on the left, either as an expression or by selecting it from Dynamic content
Then select operator equals
Finally add second entry on the right
But, if your goal is to run this copy + notify when item is modified, then you should consider this alternate approach
If you work with a Condition action block, then it should look the following:
Please note my interface is in Spanish, but when I hover the mouse over the entry on the right, you can see triggerBody()?['Modified']. If I hover the mouse over the entry on the right, I would see triggerBody()?['Created']. Finally, operator selected ' is not equal to' corresponds to not(equals())
Hope this time I understood properly your requirements so all of this explanation makes sense
thank you @efialttes for all this information and help. I will try these steps later on this week (I am pretty tied up at the beginning of the week). I will let you know if I have any better luck.
Thank you again for all your help.
I had no luck with this. I'm going to delete this flow (since it keeps running) and start a new one to see if I have better luck.
The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.
Learn to digitize and optimize business processes and connect all your applications to share data in real time.
Are you new to designing flows? What is your biggest struggle with Power Automate Designer? Help us make it more user friendly!