Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The ultimate Microsoft Fabric, Power BI, Azure AI & SQL learning event! Join us in Las Vegas from March 26-28, 2024. Use code MSCUST for a $100 discount. Register Now

Reply
Turgpat
Frequent Visitor

Problem with an ageing report - Using a date filter as a starting point as difference of two dates

Bonjour,

I'm facing a problem in an ageing report linked with the fact that my starting date for some calculations must be a date filter. I mainly have two tables, a transaction table and a rolling calendar. In a nutshell, I have :

 

  • established a relation between the Dates column in the rolling calendar and the Invoice Date column in the transaction table, as my date filter must isolate invoices produced between the selected dates
  • isolated the latest date in the filtered rolling calendar in a measure through LASTDATE. (showing correctly in my report both in a card visual and in the matrix visual rows)

 

But whenever I try to calculate the difference between the Invoices Due Date (inactive relationship with the Dates column in the rolling calendar) and the isolated last date from my rolling calendar (selected through the filter), I get a wrong calculation. Most often, it seem to calculate the DATEDIFF between the Invoice Date instead of the Invoice Due Date. I've tried several things, but I feel I'm missing something. I'm digging in my various reference sources, but I feel I might benefit from your enlightened minds.

 

Thank you in advance for your help!

 

https://we.tl/t-2mUVy3g3Od 

2 REPLIES 2
v-cgao-msft
Community Support
Community Support

Hi @Turgpat ,

 

Please check if this helps.

Patterns – DAX Patterns

If the problem is not solved, Could you provide sample data and measures and expected output? This would be helpful.

How to provide sample data in the Power BI Forum

 

Best Regards,
Gao

Community Support Team

 

If there is any post helps, then please consider Accept it as the solution  to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!

How to get your questions answered quickly -- How to provide sample data

Thank you for these sources. Unfortunately, for the moment, I didn't find something to help me track down the problem. I've included a simple PBIX file that provide a quick idea of my problem. The last column (Nb of Days Not Paid) does not provide the correct calculation between the Due Date and the last date from the Date Filter.

 

Thank you!

Helpful resources

Announcements
Fabric Community Conference

Microsoft Fabric Community Conference

Join us at our first-ever Microsoft Fabric Community Conference, March 26-28, 2024 in Las Vegas with 100+ sessions by community experts and Microsoft engineering.

February 2024 Update Carousel

Power BI Monthly Update - February 2024

Check out the February 2024 Power BI update to learn about new features.

Fabric Career Hub

Microsoft Fabric Career Hub

Explore career paths and learn resources in Fabric.

Fabric Partner Community

Microsoft Fabric Partner Community

Engage with the Fabric engineering team, hear of product updates, business opportunities, and resources in the Fabric Partner Community.

Top Solution Authors