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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
AlexisPREVOT
Helper III
Helper III

Show oldest and most recent dates

Hi,

 


I want to display a table with the oldest and most recent dates of each billing.

For example, for my XXX client, I want to see that the first billing took place on 01/01/2020 and the last billing on 07/01/2021.

 

I therefore created a table with my first invoice date (by selecting "the oldest" in the values ​​"and the name of my customers.
But I can't display the last invoice date.
I tried to make a column like this: colonne = firstdate(factures[dates].[dates]) but it does not work.

 

If anyone has an idea i will be very grateful.

 

Thank you by advance.

 

Alexis

 

1 ACCEPTED SOLUTION

@AlexisPREVOT 

maybe try this

calculate(max(fact[dates]),allexcept(table, FCC_ID))

since the screenshot is not clear, you need to modify the DAX based on your real table and column name.





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




View solution in original post

7 REPLIES 7
ryan_mayu
Super User
Super User

@AlexisPREVOT 

maybe you can try

min(factures[dates])

if you can provide the sample data and expected output , that will be better for us to provide the proper solution





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




Hi @ryan_mayu ,

 

I tested the formula but it also doesn't work.
This is what I want to achieve (boxed in red, it's a photo montage for the example ) :

 

AlexisPREVOT_0-1625206386014.png

 

So, in my first column I do have my oldest billing date : 

AlexisPREVOT_1-1625206523227.png

I therefore want to concatenate in the same table the oldest date of my invoice and the most recent date.

I hope this will help you ti help me.

 

 

@AlexisPREVOT 

maybe try this

calculate(max(fact[dates]),allexcept(table, FCC_ID))

since the screenshot is not clear, you need to modify the DAX based on your real table and column name.





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




Thank you for the response but unfortunatelley it doesn't work

@AlexisPREVOT 

could you pls provide the sample data and expected output?





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




Sorry i just retested and it works, i was the one who made a mistake in the formula. All my excuses.

Thanks for your help

you are welcome





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.