cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
jnouvel Frequent Visitor
Frequent Visitor

Help with measure and allselectec

Hello,

 

If someone can help me with my report I would be very gratefull!

I'm looking to create a new measure with total of sales in a matrix filtered by context.

 

I start with my matrix filtered  :

 

ID          SALES

A           10

B            20

C           15

D           40

 

what I want is :

 

ID          SALES          TOTAL_OF_SALES

A           10                           85

B           20                           85

C           15                           85

D           40                           85

 

 

Il I create a measure like TOTAL_OF_SALES = CALCULATE(SUM('TABLE1'[SALES]) ; ALLSELECTED('TABLE2'[ID]) )

 

I have this result :

 

ID          SALES          TOTAL_OF_SALES

A           10                           85

X                                          85

B           20                           85

C           15                           85

Z                                          85

D           40                           85

Z4                                        85

Z6                                        85

 

Every ID even those which are out of context appear... someidea to avoid this? 

 

Thanks.

 

Jerome

1 ACCEPTED SOLUTION

Accepted Solutions
jnouvel Frequent Visitor
Frequent Visitor

Re: Help with measure and allselectec

Hello guys,

 

I'm back with a solution...

 

Just need to switch my measure to 

TOTAL_OF_SALES = SUMX(VALUES('TABLE1'[ID2];CALCULATE(SUM('TABLE1'[SALES]) ; ALLSELECTED('TABLE2'[ID]) )

 

And it works perfectly!

 

sorry for the disturbance.

 

 

View solution in original post

1 REPLY 1
jnouvel Frequent Visitor
Frequent Visitor

Re: Help with measure and allselectec

Hello guys,

 

I'm back with a solution...

 

Just need to switch my measure to 

TOTAL_OF_SALES = SUMX(VALUES('TABLE1'[ID2];CALCULATE(SUM('TABLE1'[SALES]) ; ALLSELECTED('TABLE2'[ID]) )

 

And it works perfectly!

 

sorry for the disturbance.

 

 

View solution in original post

Helpful resources

Announcements
New Topics Started Badges Coming

New Topics Started Badges Coming

We're releasing new versions of the badge that everyone's talking about. ;) Check your inbox for notifications.

MBAS 2020

Save the new date (and location)!

Our business applications community is growing—so we needed a different venue, resulting in a new date and location. See you there!

Difinity Conference

Difinity Conference

The largest Power BI, Power Platform, and Data conference in New Zealand

Top Solution Authors
Top Kudoed Authors (Last 30 Days)