Forum Discussion
maximus84
7 years agoFrequent Visitor
Calculated column with sum per month by product
Hi all! Help me, please.
I have a table. I want to create a custom column for calculating the sailing sum per month by each product.
The value in each row of "Custom_Column" is the sailing sum per month by each product. I need help to write DAX construction for the "Custom_Column" creation.
My vision of this table looks like
| ProductID | SaleCount | Date | Custom_Column |
| 1 | 5 | 2019-01-01 | 24 |
| 1 | 8 | 2019-01-02 | 24 |
| 1 | 11 | 2019-01-03 | 24 |
| 2 | 6 | 2019-01-01 | 14 |
| 2 | 3 | 2019-01-02 | 14 |
| 2 | 5 | 2019-01-03 | 14 |
| 1 | 4 | 2019-02-01 | 13 |
| 1 | 6 | 2019-02-02 | 13 |
| 1 | 3 | 2019-02-03 | 13 |
| 2 | 1 | 2019-02-01 | 12 |
| 2 | 5 | 2019-02-02 | 12 |
| 2 | 6 | 2019-02-03 | 12 |
- Anonymous7 years ago
hi maximus84 ,
Please check this measure.
Product Sum = CALCULATE(SUM('Table (2)'[SaleCount]),ALLEXCEPT('Table (2)','Table (2)'[ProductID]))regards,
Naveen