cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Raul09 Regular Visitor
Regular Visitor

Create measure % of product sales

Hi,

 

I need to acomplish the % marked on RED: 

 

1.png

in this case, is the product % over the total sales of each Rep individually.

 

This is an example of the Table i'm using

2.png

 

appreciate any help, thanks in advance!

1 ACCEPTED SOLUTION

Accepted Solutions
Super User
Super User

Re: Create measure % of product sales

yes correct change the all to allselected and that should hopefully solve the issue 


Did I answer your question? Mark my post as a solution.
Proud a to be a Datanaut!
7 REPLIES 7
Super User
Super User

Re: Create measure % of product sales

as far as i can tell you need to create 3 measures; 

 

 

Sales = sum(amount)

Total Sales = CALCULATE(sum(Table1[amount]), ALL(Table1))

% of Total = CALCULATE(DIVIDE([Sales],[Total Sales] ))

 

then when you place your categories on a visual it shoud dynamically calcuate the %

 


Did I answer your question? Mark my post as a solution.
Proud a to be a Datanaut!
Raul09 Regular Visitor
Regular Visitor

Re: Create measure % of product sales

I've created all measures as you suggested but is not working properly.

 

it shows way more than 100%, even using it with out filtering the reps

Super User
Super User

Re: Create measure % of product sales

you will have to show me exactly what you are doing otherwise it wont be possible to isolate the problem.


Did I answer your question? Mark my post as a solution.
Proud a to be a Datanaut!
Raul09 Regular Visitor
Regular Visitor

Re: Create measure % of product sales

i think the problem is this.

 

in my table i have sales from previous months, so using the measure Total Sales = CALCULATE(sum(Table1[amount]), ALL(Table1)) is actually calculating ALL sales and not using my calendar date filter, am i right?

 

how can i solve this?

Super User
Super User

Re: Create measure % of product sales

yes correct change the all to allselected and that should hopefully solve the issue 


Did I answer your question? Mark my post as a solution.
Proud a to be a Datanaut!
Raul09 Regular Visitor
Regular Visitor

Re: Create measure % of product sales

Thanks Vanessa! Smiley Happy

qs Regular Visitor
Regular Visitor

Re: Create measure % of product sales

Hi Vanessa,

Sorry to jump into the middle of your discussion with Raul. I have a similar problem and I thought you might be able to help me. If I use the same table used by Raul, my problem is; How to calculate the percentage of beers over the total number of item's field? In other words, I have to divide  2 over 6 to calculate beer's %, for Vodka 1 over 6, for Coke 1 over 6 etc.
Thanks

Qmars