我想找到MAX(FYandFW num)
基于每个来源的内容。
样本数据集:
Source FYandFW num sum
Company A 202453 1
Company A 202452 2
Company A 202451 3
Company B 202501 4
Company B 202502 5
Company B 202453 6
Amt =
VAR i = VALUES('Table'[Source])
VAR j = VALUES('Table'[FYandFW num])
VAR t =
TOPN(1,
CALCULATETABLE('Table', REMOVEFILTERS(), i),
'Table'[FYandFW num], DESC)
RETURN
CALCULATE(SUM('Table'[sum]),t , j)
预期答案是Amt = 5 + 1
尝试这个方法: