Some tips for filtering dates in D365FO

Some tips for filtering dates in D365FO

By working with D365FO you often need date filters for making selections of data. In my trainings and consultancy projects I see that not all users now the several available options. So to help a bit I share three examples in this article:

1. Using the D or T in the Date field

In filters you can use the criteria D (session date) or T (actual date) in the date field:

No alt text provided for this image

This value will always filter on the 'today' date. In this example I have entered the value T in the voucher transactions inquiry. The result of the value is that I will only see the voucher transactions posted today:

No alt text provided for this image

When I use the same filter tomorrow I will only see transactions of August 5, no need to change the filter for that or enter each date every day. Because of this standard value I don't need to specify the date every time when I want to use this filter if I want only data of today.

2. Using the advanced date queries

For some purposes it can be that you want to see data of the last X amount of days or the next X amount of days. That can be for manually tasks, but also in batch jobs. In that case you can use the advanced date queries.

By example if I want to see all posted transactions of the last 30 days, I can use the following DayRange filter:

No alt text provided for this image

With this criteria in the voucher transactions inquiry, I will see the posted transactions of the last 30 days (including today):

No alt text provided for this image

There are multiple options for date/day ranges in the advanced date queries, so for more possibilities and examples see the official Microsoft page with the filter options: https://docs.microsoft.com/en-us/dynamics365/fin-ops-core/fin-ops/get-started/advanced-filtering-query-options

3. Date intervals

In some functionalities and reports you have the field Date interval available, by example in the trial balance:

No alt text provided for this image

You have two options then:

  1. You don't use the date intervals and have to specify the From date and To date.
  2. You use the date interval which will fill in the corresponding From date and To date automatically by opening the functionality

So the date intervals can enter the From date and To date automatically. For doing this, you can set up the selections that you want to use in each date interval. By example I can make a date interval for the current period where I define that I want a date range for the financial period. When I select this date interval, the date selection will always be the dates of the current period based on the session date. In my case on August 4, the From date and To date will be for the month August:

No alt text provided for this image

When the session date will be changed to a new period because the new period started or you change the session date manually, automatically the date selection will be changed to the new period based on this entered date interval. So when I change my session date to a date in September and open the trial balance again, the From date and To date are automatically changed to September:

No alt text provided for this image

You can create as many date intervals as you need. In each date interval you define the starting date of the date selection and the ending date of the date selection. By example the date interval for current period will be created with the options to begin at the start of the From date period type 'Period' and stop at the end of the period:

No alt text provided for this image

The system will fall back on the fiscal calendar and recognizes the periods. So with that you can also make a date interval where the presented data is based on year to date.

No alt text provided for this image

By opening the trial balance you always see the From date and To date related to year to date (tomorrow the To date will be changed automatically to August 5th):

No alt text provided for this image

Hope this helps!

Ali Asghar

D365 F&O (ERP) SCM, Manufacturing, Warehouse

11 个月

Amazing!!!

回复
Tim O'Reilly

IT Dynamics 365 Application Manager at Matthew Algie

1 年

Hi Hylke, thanks for the post. I am looking to filter records created more than half an hour from 'now' relative to when filtered. I am aware of the (LessThanUtcNow()) but do you know we can add time-windows into the brackets, as we do with the DayRange function, and if so what would be the format? On this occasion the filter being applied is to a batch job parameter.

回复
Saqib Shahzad Farooqi - PMP?, ITIL?, COBIT?

Digital Transformation Enabler | Driving I.T Enabled Business Processes

2 年
Islam Khaled

Microsoft Dynamics 365 - ERP Unit Manager

2 年

Very helpful

要查看或添加评论,请登录

Hylke Britstra的更多文章

社区洞察

其他会员也浏览了