cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Frequent Visitor

Flow Formatting

I have copied every similar example I can find and still am having issues.  Trying to build a simple flow to send an email when an on call shift starts.  The On Call schedule is saved in a SharePoint list.  

 

My flow is:

Recurrance - daily at 7:45

Get Items from my SharePoint List

Apply to each

Value (from sharepoint list

Condition:@equals(formatdateandtime(items('Apply_to_each')?['MOC_x0020_Start'], 'yyyy-MM-dd'), formatDateTime(utcNow(),  'yyyy-MM-dd'))

 

If yes, send an email

 

It keeps failing with no match, I think it has something to do with date format but I am out of ideas...

 

thanks in advance. 

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Anonymous
Not applicable

Re: Flow Formatting

I currently use a flow that checks a date against today's. This is what I use:

 

 

@equals(formatDateTime(items('Apply_to_each_2')?['dueDateTime'], 'MM/dd/yyyy'), formatDateTime(utcNow(),'MM/dd/yyyy')) 

 

 

For you it'll be:

 

 

@equals(formatDateTime(items('Apply_to_each')?['MOC_x0020_Start'], 'MM/dd/yyyy'), formatDateTime(utcNow(),'MM/dd/yyyy')) 

 

I remember struggling with this and IIRC it has something to do with the format. Flow is a little tricky when it comes to comparing dates. Your format function is also quite dubious in your first parameter for the comparison. If this doesn't work please provide the errors you were getting before and after.

 

I hope that helps!

 

View solution in original post

2 REPLIES 2
Highlighted
Anonymous
Not applicable

Re: Flow Formatting

I currently use a flow that checks a date against today's. This is what I use:

 

 

@equals(formatDateTime(items('Apply_to_each_2')?['dueDateTime'], 'MM/dd/yyyy'), formatDateTime(utcNow(),'MM/dd/yyyy')) 

 

 

For you it'll be:

 

 

@equals(formatDateTime(items('Apply_to_each')?['MOC_x0020_Start'], 'MM/dd/yyyy'), formatDateTime(utcNow(),'MM/dd/yyyy')) 

 

I remember struggling with this and IIRC it has something to do with the format. Flow is a little tricky when it comes to comparing dates. Your format function is also quite dubious in your first parameter for the comparison. If this doesn't work please provide the errors you were getting before and after.

 

I hope that helps!

 

View solution in original post

Highlighted
Frequent Visitor

Re: Flow Formatting

You are my hero!!  Thank you!!  Worked like a charm!

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

Upcoming Events

Experience what’s next for Power Automate

See the latest Power Automate innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Top Solution Authors
Top Kudoed Authors
Users online (2,807)