cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
maximus84 Frequent Visitor
Frequent 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

ProductIDSaleCountDateCustom_Column
152019-01-0124
182019-01-0224
1112019-01-0324
262019-01-0114
232019-01-0214
252019-01-0314
142019-02-0113
162019-02-0213
132019-02-0313
212019-02-0112
252019-02-0212
262019-02-0312

 

1 ACCEPTED SOLUTION

Accepted Solutions
Anonymous
Not applicable

Re: Calculated column with sum per month by product

hi @maximus84 ,

 

Please check this measure.

Product Sum = CALCULATE(SUM('Table (2)'[SaleCount]),ALLEXCEPT('Table (2)','Table (2)'[ProductID]))

Capture.JPG

 

regards,

Naveen

View solution in original post

5 REPLIES 5
amkhullar Regular Visitor
Regular Visitor

Re: Calculated column with sum per month by product

Use Group By Feature
maximus84 Frequent Visitor
Frequent Visitor

Re: Calculated column with sum per month by product

I am new to DAX. Can you show an example?

Anonymous
Not applicable

Re: Calculated column with sum per month by product

hi @maximus84 ,

 

Please check this measure.

Product Sum = CALCULATE(SUM('Table (2)'[SaleCount]),ALLEXCEPT('Table (2)','Table (2)'[ProductID]))

Capture.JPG

 

regards,

Naveen

View solution in original post

maximus84 Frequent Visitor
Frequent Visitor

Re: Calculated column with sum per month by product

Thanx a lot to @Anonymous 

Anonymous
Not applicable

Re: Calculated column with sum per month by product

welcome @maximus84 

Helpful resources

Announcements
Exclusive LIVE Community Event #3 – Ask Arun Anything

Exclusive LIVE Community Event #3 – Ask Arun Anything

Join us in the third Triple A event!

Meet the 2020 Season 1 Power BI Super Users!

Meet the 2020 Season 1 Power BI Super Users!

It’s the start of a new Super User season! Learn all about the new Super Users and brand-new tiered recognition system.

Super User Challenge: Can You Solve These?

Super User Challenge: Can You Solve These?

We're celebrating the start of the New Super User season with our first ever Super User 'Can You Solve These?' challenge.

Power BI Desktop Update - February 2020

Power BI Desktop Update - February 2020

We are super excited for our update this month, as we are releasing two of our top community requests!

Power Platform Online Conference

Power Platform Online Conference

Join us for the first ever Power Platform Online Conference!

Top Solution Authors