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.
Hi,
I have the following table Sales with columns 'Sales volume' and 'Year-Month' where Year-Month is 2019-01, 2019-02 etc. and is Text format.
I have the following formula for a measure:
Cumulative Sales = calculate( sum('Sales'[Sales volume]), filter(allselected('Sales'[Year-Month]), ISONORAFTER('Sales'[Year-Month], max('Sales'[Year-Month]),desc)))
Solved! Go to Solution.
HI @Anonymous ,
If '2019-04' not real existed in your table, formula calculation will skip and not calculate on these 'not exist' records.
You can consider to add a calendar table as category and write measure formula to summary sale table amounts based on current date.(calendar not has relationship to sales table)
If above not help, can you please share some sample data for test?
Regards,
Xiaoxin Sheng
HI @Anonymous ,
If '2019-04' not real existed in your table, formula calculation will skip and not calculate on these 'not exist' records.
You can consider to add a calendar table as category and write measure formula to summary sale table amounts based on current date.(calendar not has relationship to sales table)
If above not help, can you please share some sample data for test?
Regards,
Xiaoxin Sheng
Thank you @v-shex-msft I transferred the measure to the calendar table and this is working now.
Hi Laura,
I try the same as you, and when i put cumulativeSales in the matrix i have seen the result you expect.
First of all, in the year-month column you must have the value of 2019-04, with the blank/null value.
And with your formula:
"CumulativeSales = calculate(
Thanks @MMM - so does there have to be a null row for 2019-04 in the raw data? As I mentioned in my first post, this isn't the case with my data. Is there a way this can work without the null row? The data is imported from another system so it will be tricky for me to add a null row in.
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 | |
100 | |
80 | |
64 | |
58 |
User | Count |
---|---|
148 | |
111 | |
93 | |
84 | |
66 |