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.
I was able to make a measure that shows the sum of a total for previous week, but however I want to utilize the percent column into it's own column so I can use the slicer for percent change. Any way of doing a new measure column of previous week totals?
Solved! Go to Solution.
I figured it out!!
Lasts Week Total = var LastWeekComp = SUMX( FILTER( Sheet1, Sheet1[Date] = EARLIER(Sheet1[Date]) - 7 ) , Sheet1[Total]) return LastWeekComp
Hi @weixiangzhang ,
I'm not so clear for your description, can you please share some sample data with expected result to help us clarify your requirement?
If you mean display the percent of current sales, you can try to use following measure formula:
Percent = VAR currDate = MAX ( Table[Date] ) RETURN DIVIDE ( SUM ( Table[Amount] ), CALCULATE ( SUM ( Table[Amount] ), FILTER ( ALLSELECTED ( Table ), [Date] = DATE ( YEAR ( currDate ), MONTH ( currDate ), DAY ( currDate ) - 7 ) ), VALUES ( Table[Category] ) ), -1 )
Regards,
Xiaoxin Sheng
I figured it out!!
Lasts Week Total = var LastWeekComp = SUMX( FILTER( Sheet1, Sheet1[Date] = EARLIER(Sheet1[Date]) - 7 ) , Sheet1[Total]) return LastWeekComp
Thank you! I understand how to make a measure, the issue is that I can't convert that to a column. I want to be able to convert it to a column so I can use it as a filter.
Hi @weixiangzhang ,
Can you please share a pbix file with some sample data to test?
Regards,
Xiaoxin Sheng
Yes, this is what I would like to do.
I would like to turn Last Week's Value as a column rather than a measure, so I can use a slicer on it. Is that possible?
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 |
---|---|
114 | |
101 | |
78 | |
75 | |
49 |
User | Count |
---|---|
145 | |
108 | |
107 | |
89 | |
61 |