cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
New Member

Dynamics 365 Filter date

I'm new to Flows but from what I've read I should be able to trigger events based on information within Dynamics 365 entities. I'm trying to find all records in an entity within a specific date range.  This will be a recurring process, and each record found would create an email to a contact within that entity.

 

So far I have built the recurrance, and added the email, but I can't figure out the expression to find records within the date period.  Can someone offer advise?  The date field is 'new_proposalsentdate' and the time period I'm targeting older than 5 days but less than 6.

 

I have this so far:

 

flow-1.JPG

 

2 REPLIES 2
Highlighted
Community Support
Community Support

Re: Dynamics 365 Filter date

Hi @pfinigan,

 

According to your description, I have made a simple test on my side with the entity Opportunities.

 

I use the Odata filter to filter items that actual close date within a specific date range.

 

The code I am using is:

Actualclosedate ge formatDateTime(addDays(utcNow(),-5),'yyyy-MM-dd') and actualclosedate le formatDateTime(addDays(utcNow(),6),'yyyy-MM-dd')

 

It just works fine. Please take the following screenshot for a reference:

1.PNG2.PNG

 

Please take the following doc on Odata filter query for more details:

https://docs.microsoft.com/en-us/previous-versions/dynamicsnav-2016/hh169248(v=nav.90)

 

Please try it on your side and feel free post back if you need more help.

 

 

Best regards,

Mabel Mao

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Highlighted
Administrator
Administrator

Re: Dynamics 365 Filter date

Hello, @pfinigan!

 

Thank you for posting on the Flow Community Forum! Have you had an opportunity to apply @v-yamao-msft‘s recommendation to adapt your Flow? If yes, and you find that solution to be satisfactory, please go ahead and click “Accept as Solution” so that this thread will be marked for other users to easily identify!


Thank you for being an active member of the Flow Community!

 

-Gabriel
Flow Community Manager

-Gabriel
Microsoft Power Automate Community Manager
Are YOU a member of your local Power Automate User Group?
Fill out This Form to claim your Community User Group Member Badge!

Helpful resources

Announcements
firstImage

Super User Program Update

Three Super User rank tiers have been launched!

firstImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

firstImage

Join the new Power Virtual Agents Community!

We are excited to announce the launch of Power Virtual Agents Community. Check it out now!

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!

Top Solution Authors
Users online (7,416)