cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
biuser99
Level: Powered On

Compare entered date with existing dates in PowerApps/Flow

Hello,

 

I have a date entry field in powerapps where users can select multiple dates. After user enters the dates, I need to check date difference between the entered date(s) and existing dates and trigger email notification if the difference between 2 dates is less than 90 days.

 

The column is mapped to SharePoint list.

 

Any inputs please

 

Thank You

3 REPLIES 3
Community Support Team
Community Support Team

Re: Compare entered date with existing dates in PowerApps/Flow

Hi @biuser99,

 

Currently, there is no function like DateDif() function that could be used to calculate the Days between two dates. AS a workaround, you can use the addDays() function instead.

Annotation 2019-11-29 135343.png

If  addDays(variables('Date1'), 90) is greater than variables('Date2'), it means between Date 1 and Date 2 is less than 90 Days, or it is greater than 90 days.

Best Regards,
Community Support Team _ Lin Tu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Highlighted
biuser99
Level: Powered On

Re: Compare entered date with existing dates in PowerApps/Flow

Hi Lin,

Thanks for the reply. The problem is I have to compare dates within the same field and not two different fields. I'm not sure if the below approach works for my scenario. Any thoughts?

Thank You
biuser99
Level: Powered On

Re: Compare entered date with existing dates in PowerApps/Flow

Hello,

 

I have designed the below but running into loop and triggering notification for all rows. Any advice how to resolve this issue?Flow.JPG

Helpful resources

Announcements
firstImage

Power Platform Online Conference

Speakers, submit your sessions now! Call for speakers ends Feb. 10!

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

firstImage

Incoming: New and improved badges!

We've given our badges an overhaul and also added some brand new ones!

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Power Automate Community Video Gallery!

Top Solution Authors
Top Kudoed Authors (Last 30 Days)
Users online (5,557)