Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
Any suggestions on how this expression below can be updated so the Price shown is not a sum but the prior month price based on a filter for certain Holdings Date.
30dayprice - 2 = CALCULATE(SUM(Holdings[Price]), DATEADD(Holdings[Holdings Date], -1, MONTH))
Solved! Go to Solution.
Hi CJANE,
As a general solution, modify you measure like below and check if it can meet yoru requirement.
30dayprice - 2 = VAR Previous_Month = EDATE ( MAX ( Holdings[Holdings Date] ), -1 ) RETURN CALCULATE ( MAX ( Holdings[Price] ), FILTER ( Holdings, Holdings[Holdings Date] = Previous_Month ) )
Hope it's helpful to you.
Jimmy Tao
Hi CJANE,
As a general solution, modify you measure like below and check if it can meet yoru requirement.
30dayprice - 2 = VAR Previous_Month = EDATE ( MAX ( Holdings[Holdings Date] ), -1 ) RETURN CALCULATE ( MAX ( Holdings[Price] ), FILTER ( Holdings, Holdings[Holdings Date] = Previous_Month ) )
Hope it's helpful to you.
Jimmy Tao
User | Count |
---|---|
107 | |
89 | |
81 | |
76 | |
73 |
User | Count |
---|---|
112 | |
104 | |
96 | |
74 | |
66 |