Forum Discussion
PBIViz_2024
Advocate I
1 year agoDirect Query-Calculate function-No values
Hi All, I have PBI Dashbaord developed initially using import and I am trying to do the same using Direct query.howver below function works well in import but no values resulting in direct query....
Anonymous
1 year agoNot applicable
Hi PBIViz_2024
Pleasre try the following Dax:
Total Tonnage-Latest =
VAR Latest_time = CALCULATE(MAXX(ALL(Table1), Table1[datetime_val]))
VAR _output =
CALCULATE(
SUM(Table1[value]),
FILTER(
Table1,
Table1[datetime_val] = Latest_time
),
ALLSELECTED(Dimensiontable1[category])
)
RETURN _output
Best Regards,
Jayleny
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.