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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
RubenMerino
Frequent Visitor

DATEDIFF based on measure

Hi 


I have two table:

 

  1. Calendari_des_de_2018: And this table it's only a calendar table.
  2. Llista_Espera: And this table has mean data.

I need measure , the name IE01, that count de difference of day between de column "Data Baixa" of Llista_Espera table and the value of "Data_maxima_seleccio_filtre" than has the funcion "Data_maxima_seleccio_filtre = LASTDATE(Calendari_des_de_2018[Date])".

The idea is, when you us the slider to filter a day the function "Data_maxima_seleccion_filter" take the lastdate and them in the measure of difference of day between change the number of difference day.

This is the final table than I need.

 

RubenMerino_1-1708435000705.png

 

Thanks. 

1 ACCEPTED SOLUTION

Hi @Greg_Deckler 

Finally
I point that I forget, I delate de relation between tables 

RubenMerino_0-1708438617254.png

RubenMerino_1-1708438646531.png

 

 

View solution in original post

3 REPLIES 3
Greg_Deckler
Super User
Super User

@RubenMerino Seems like:

Measure = 
  ( MAX('Llista_Espera'[Data Baixa]) - [Data_maxima_seleccion_filter] ) * 1.


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
Power BI Cookbook Third Edition (Color)

DAX is easy, CALCULATE makes DAX hard...

Hi @Greg_Deckler 

Finally
I point that I forget, I delate de relation between tables 

RubenMerino_0-1708438617254.png

RubenMerino_1-1708438646531.png

 

 

Hi @Greg_Deckler 

First, thank very much for answer so fast

But I think it dosen't work

RubenMerino_0-1708436798052.png

 

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

Check out the June 2025 Power BI update to learn about new features.

June 2025 community update carousel

Fabric Community Update - June 2025

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