The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.
Hi,
I am creating a measure through which whatever date range is being selected in date filter get the max year for it and calculate the spend for that year for all Qtr's of which data is being present.
Kindly review the below measure which I have created and attachement and please suggest the way forward for it. I need the total spend for Max year disregard the date selected in filter.
Hi, @laraibashfaq
Try something like:
MaxyearAmount =
VAR MaxYear =
CALCULATE (
MAX ( 'Date'[DateValue] ),
ALLEXCEPT ( 'Date', 'Date'[DateValue] )
)
RETURN
CALCULATE (
MAX ( [Spend] ),
FILTER (
ALLEXCEPT ( 'Date', 'Date'[DateValue] ),
'Date'[DateValue] = MaxYear
)
)
Proud to be a Super User!
Nops, this function doesn't work
User | Count |
---|---|
58 | |
56 | |
55 | |
50 | |
32 |
User | Count |
---|---|
171 | |
87 | |
70 | |
46 | |
45 |