Microsoft Fabric Community Conference 2025, March 31 - April 2, Las Vegas, Nevada. Use code FABINSIDER for a $400 discount.
Register nowThe Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.
Here we have Inspected dates as 26th Apr, 28th Apr, 3rd May, 4th May, 12th May, and 13th May (this is the latest date)
based on the vehicle number & latest date we need to get the max damage intensity value.
I have written dax expression as (calculated column)
max value of damage intensity =
calculate(MAX(''Table1[damageIntensity]),ALLEXCEPT(Table1,Table1[Vehicle Number
]),KEEPFILTERS(LASTDATE(Table1[Inspected Date])))
But it is giving a different output
like for 26th Apr
and for 28th Apr
for each different date, it is giving different max damage intensity values. but I need output as max damage intensity value for the latest date (i.e 13th may)
Irrespective of each date, we need the max damage intensity value on the latest date. i.e value 6.
please help me to write/update my DAX expression.
Solved! Go to Solution.
Hi @sharath123
you can use
max value of damage intensity =
VAR VehicleTable =
CALCULATETABLE ( Table1, ALLEXCEPT ( Table1, Table1[Vehicle Number] ) )
VAR MaxDate =
MAXX ( VehicleTable, Table1[Inspected Date] )
RETURN
MAXX (
FILTER ( VehicleTable, Table1[Inspected Date] = MaxDate ),
Table1[damageIntensity]
)
Hi @sharath123
you can use
max value of damage intensity =
VAR VehicleTable =
CALCULATETABLE ( Table1, ALLEXCEPT ( Table1, Table1[Vehicle Number] ) )
VAR MaxDate =
MAXX ( VehicleTable, Table1[Inspected Date] )
RETURN
MAXX (
FILTER ( VehicleTable, Table1[Inspected Date] = MaxDate ),
Table1[damageIntensity]
)
Thanks @tamerj1 It worked for me. you have given a detailed DAX expression, Thanks once again.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Check out the February 2025 Power BI update to learn about new features.
User | Count |
---|---|
25 | |
12 | |
10 | |
9 | |
9 |
User | Count |
---|---|
17 | |
14 | |
13 | |
13 | |
12 |