cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
JimmyWork
Power Participant
Power Participant

Send email on date from sharepoint column

Hi

 

I have some questions, my flow is working but i do get ActionBranchingConditionNotSatisfied. This might be correct from a logic point of view as one item will be true to the condition and one will not be true. Im just wondering if im doing this correct.

 

Short description.

SharePoint List with a Date column named Renewel date.
I want flow to send an email when a item in the list is 14 days from the Renewel date and another email when its 7 days from the Renewal date.

 

I start my flow with a Recurrence that will run each day.
Then i do Get items.

Apply to each.

 

Now my conditions

First condition is set to utcnow plus 14 days

Second condition is set to utcnow plus 7 days.

 

Everything works fine emails are sent out correct but in my flow i can see ActionBranchingConditionNotSatisfied.

I guess this is due to if the first item in the list does not meet the condition i get that message even if the second item will meet the condition.

 

So if i have 50 items and the first item in that list does not meet the conditons then in flow it will look like it did not send any email even if the conditon was meet by 4 other items.

 

Im not sure if this is correct, but form pure logic i guess it's correct?

1 ACCEPTED SOLUTION

Accepted Solutions

Hey @JimmyWork 

 

Note that there is a space in the column name that you have typed. Just type RenewalDate le 'expression' and this should work. 

 

le-less than or equal to

ge-greater than or equal to

 

you can place teh operator accordingly

 

Hope this Helps!

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

View solution in original post

14 REPLIES 14
Gaznae
Advocate III
Advocate III

Hi, @JimmyWork 

 

ActionBranchingConditionNotSatisfied is likely being caused by using Equals in the logic of your condition.

 

Are you using formatdatetime() to make sure the dates coming from SPO are the same as the format of the output from utcnow() ?

JimmyWork
Power Participant
Power Participant

@Gaznae 

Yes im using 

formatDateTime(addDays(utcNow(), 14), 'yyyy-MM-dd')
And if the 1st item in the list does not meet this condition it will say ActionBranchingConditionNotSatisfied. The flow will still send me an email if item 2 and item 3 meets the condition so the flow works. But it will show ActionBranchingConditionNotSatisfied because the first item in the list will not meet the condition so it looks like no email is being sent out and i cant really check the flow because all i see is ActionBranchingConditionNotSatisfied.
 
It looks like if the first item it pulls does not match the condition it will say ActionBranchingConditionNotSatisfied. But it will also still send the email for any item that meet the condition

@JimmyWork  - Does it still give you the same error if you change your condition to Contains?

JimmyWork
Power Participant
Power Participant

@Gaznae 

 

Yes same error if i use contains.

I belive it checks all items but the flow will only display if the first item actually meet the condition, if the second or third item meets the condition flows logic would be that the first item it checked still did not meet the condition.

yashag2255
Dual Super User II
Dual Super User II

Hi @JimmyWork 

 

I cleaner way to do this would be using filter queries:fgew.PNG

Ensure that you are typing the column name correctly and the expression is in single quotes. Expression:

formatDateTime(addDays(utcNow(),14),'MM-dd-yyyy')
formatDateTime(addDays(utcNow(),7),'MM-dd-yyyy')

This will return items with the above criteria only and you can send an email to all the items returned in the action. 

 

Hope this Helps!

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

@yashag2255 

This looks nice, i just tested it and i got an error.

Now i tested with 1 and 2 days i set daye to yyyy-MM-dd as this is how my column is setup

 

"message": "The expression \"formatDateTime(addDays(utcNow(),1),'yyyy-MM-dd)\nformatDateTime(addDays(utcNow(),2),'yyyy-MM-dd)\" is not valid.\r\nclientRequestId: 8196b514-36d1-4d37-9471-07bf7ea3a7da\r\nserviceRequestId:

Hey @JimmyWork 

 

Can you please share a screenshot of the flow? On the filter query and the expression>

Hey @JimmyWork 

 

I can see that you are missing an end to the single quote in the expression. formatDateTime(addDays(utcNow(),1),'yyyy-MM-dd')

 

Hope this Helps!

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

I can't get any dynaic content in the Filter query so i type my Column name manually

 

2019-09-24 10_07_05-Edit your flow _ Microsoft Flow.png

Hey @JimmyWork 

 

Note that there is a space in the column name that you have typed. Just type RenewalDate le 'expression' and this should work. 

 

le-less than or equal to

ge-greater than or equal to

 

you can place teh operator accordingly

 

Hope this Helps!

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

View solution in original post

@yashag2255 Thank i tested that still same issue looks like i cant filter it because i cant get the column.

 

"message": "The expression \"Renewal Date '2019-09-25' or Renewal Date'2019-09-26'\n\" is not valid.\r\nclientRequestId:
 
Using:
formatDateTime(addDays(utcNow(), 1), 'yyyy-MM-dd')

@yashag2255 Thanks but i tested it without the space also.

 

"message": "The expression \"RenewalDate '2019-09-25' or RenewalDate'2019-09-26'\n\" is not valid.\r\nclientRequestId: 4ad41f15-ee30-4aa5-add3-af74acc56368\r\nserviceRequestId

@JimmyWork 

 

You need to place the operator between the column name and the expression. 

 

RenewalDate le 'exp' or RenewalDate le 'exp'

 

Hope this Helps!

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

@yashag2255 Thank you so much, i missed entering to operator.

Again thank you so much

Helpful resources

Announcements
MPA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Welcome Super Users.jpg

Super User Season 2

Congratulations, the new Super User Season 2 for 2021 has started!

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Top Solution Authors
Users online (1,484)