Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Anonymous
Not applicable

Create measure for quota based on values in one column and filter on other column

Hi there, 

 

Basically I have two products (A and B) and I want to create the quota of the sold product A in a specific month:

Sales_of_Product_A / (Sales_of_Product_B + Sales_of_Product_A)

The table is already filtered for the specific month, therefore I will only need to sum the specific sales for the different products and then bring them into the above formula. 

 

Product Sales
A3
B2
B1
A4
B4
A3

 --> Output would be: Quota=(3+4+3)/(3+2+1+4+4+3)

 

 

Thank you in advance!

1 ACCEPTED SOLUTION
camargos88
Community Champion
Community Champion

@Anonymous ,

 

Try this measure:

_Output = DIVIDE(CALCULATE(SUM('Table'[Sales]), 'Table'[Product ] = "A"), CALCULATE(SUM('Table'[Sales]), ALL('Table'[Product ])))


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!



View solution in original post

3 REPLIES 3
camargos88
Community Champion
Community Champion

@Anonymous ,

 

Select the column or measure -> Column Tools -> Format -> Percentage



Did I answer your question? Mark my post as a solution!

Proud to be a Super User!



camargos88
Community Champion
Community Champion

@Anonymous ,

 

Try this measure:

_Output = DIVIDE(CALCULATE(SUM('Table'[Sales]), 'Table'[Product ] = "A"), CALCULATE(SUM('Table'[Sales]), ALL('Table'[Product ])))


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!



Anonymous
Not applicable

Thanks so much!! This works! Do you know how to convert this to the percentage-format now?

Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 community update carousel

Fabric Community Update - June 2025

Find out what's new and trending in the Fabric community.