cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
pfinigan
Level: Power Up

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
Community Support Team
Community Support Team

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.
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
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 Kudoed Authors (Last 30 Days)
Users online (4,448)