Check your eligibility for this 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700.
Get StartedDon't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.
I have the following DAX:
Hello @rwong1,
Can you please try this:
VAR _FirstSelectedMonth =
CALCULATE(MIN('Date'[MonthID]), ALLSELECTED('Date'))
VAR _YearOfFirstSelectedMonth =
CALCULATE(MIN('Date'[Year]), ALLSELECTED('Date'))
VAR _PriorMonth =
IF(_FirstSelectedMonth > 1, _FirstSelectedMonth - 1, 12)
VAR _YearOfPriorMonth =
IF(_FirstSelectedMonth > 1, _YearOfFirstSelectedMonth, _YearOfFirstSelectedMonth - 1)
VAR _A =
CALCULATE (
AVERAGEX ( VALUES ( 'Date'[Mo Cal Yr] ), [Total Assets] ),
FILTER (
ALL ( 'Date' ),
'Date'[MonthID] = _PriorMonth && 'Date'[Year] = _YearOfPriorMonth
)
)
Hi Shair,
I got a syntax error. I'm not sure why.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.
Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.
User | Count |
---|---|
21 | |
15 | |
14 | |
11 | |
7 |
User | Count |
---|---|
26 | |
24 | |
12 | |
11 | |
10 |