cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Helper I
Helper I

Measure sum accross product types

Hi,

My model is as in the first figure. I should also mention that I do have startdate and enddate in the model which are related to the periode (2010 have startdate 2020-10-01 and enddate 2020-10-31).

For each ProductID of ProductType = Main I need sum of all invoice lines for the CustID having that ProductID for each periode. For the Qty I need the Qty for the ProductType Main only. Anyway to solve this in a measure?

JGG_0-1606315642447.png

 

In addition I need to identify and handle to special cases:

case 1: Change of Main and AddOn in the periode
case 2: Change of only Main in the periode

(Note that the sum of Qty for Main = sum of Qty for AddOn for each CustID and Periode.)

 

How do I identify and handle these cases in a measure (or perhaps two)?

 

Case 1:

JGG_1-1606316987245.png

 

Case 2:

JGG_2-1606317017295.png

 

regards JG

1 REPLY 1
Microsoft
Microsoft

Hi @JGG ,

 

Would you please show more details about how  do you distinguish Case1 from Case2?

 

Best Regards,

Dedmon Dai

 

Helpful resources

Announcements
secondImage

Experience what’s next for Power BI

Join us for an in-depth look at the new Power BI features and capabilities at the free Microsoft Business Applications Launch Event.

secondImage

Power BI Women

Join our monthly meetings and learning sessions.

secondImage

Congratulations!

We are excited to announce the Power BI Super Users!

secondImage

The largest Power BI virtual conference

100+ sessions, 100+ speakers, Product managers, MVPs, and experts. All about Power BI. Attend online or watch the recordings.

Top Solution Authors
Top Kudoed Authors