Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hello I'm new to powerBI
Is there a way to create a variable or parameter like vMaxYear = year(max(TrxDate)) and then use this parameter or variable in the filter of a calculate Dax expression?
You could declare a variable as below
LatestYearSumTotal =
VAR MaxYear = YEAR(max(Orders[OrderDate]))
RETURN
CALCULATE(
SUM(Orders[Freight]),FILTER(Orders,YEAR('Orders'[OrderDate])=MaxYear))
So the answer is probably yes, but would need more specifics.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
111 | |
96 | |
80 | |
68 | |
59 |
User | Count |
---|---|
150 | |
119 | |
104 | |
87 | |
67 |