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

Get percentage based on three columns/ three different values

Good Afternoon,

 

I am trying to divide Rating/Question (In this case, PRSQ5000) by the total count of 4006.

Manually I was been able to, but since I need to use an slicer the percentage need to update accordingly.

BenwillLopez_0-1664303144338.png

I tried converting the 84 to Show as Value: Percentage of Grand Total and the result I get is always 100%. Below picture for reference of the fields and applied filters:

BenwillLopez_1-1664303419544.png

I did the following (Sum of Rating of 1 and question: PRSQ5000 then divided by the grand total of 4009) but it did not work as expected even tho I got the expected percentage:

BenwillLopez_2-1664303553276.png

I would greatly apprecite if someone with knowledge could contact me for more details.

 

 

 

1 ACCEPTED SOLUTION

Hi , @Anonymous 

Here are the steps you can refer to :

(1)This is my test data which is the same as yours:

vyueyunzhmsft_0-1664440900031.png

(2)We can create two measures :

Response = IF( HASONEVALUE('Sheet3'[RATING]), COUNT('Sheet3'[QUESTION|]) , FORMAT( DIVIDE( SUM('Sheet3'[RATING]) ,  COUNT('Sheet3'[RATING])),"0.00")  )
% = DIVIDE([Response], CALCULATE( COUNT('Sheet3'[KPI_SURVEY_ID|]), ALLSELECTED('Sheet3'[RATING]) ))

(3)Then we can put the measure and the filed we need in the Matrix visual and we will meet your need:

vyueyunzhmsft_1-1664440970957.png

If this method does not meet your needs, you can provide us with your special sample data and the desired output sample data in the form of tables, so that we can better help you solve the problem.

 

Best Regards,

Aniya Zhang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly

 

 

 

 

 

View solution in original post

5 REPLIES 5
v-yueyunzh-msft
Community Support
Community Support

Hi , @Anonymous 

According to your description,  you can put your field in a Matrix visual and then write a measure to implement it according to your needs.

For your question,I don't have a clear idea which field your numerator and denominator come from, and how [Rating] is grouped,can you provide us with your special sample data and the desired output sample data in the form of tables, so that we can better help you solve the problem.

 

Best Regards,

Aniya Zhang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly

Anonymous
Not applicable

Good morning, 

 

Thanks! I will try the matrix. Providing additional information below;

File download: https://anonfiles.com/udJ5jfA3y9/KPI_s_Draft_pbix

 

Numerator: column.QUESTION and column.RATING

Denominator: column.KPI_SURVEY_ID (This is the total count to be divided by)

The outputs should be getting the percentage of each rating under the specific question. The image I uploaded can be used as reference, I will include on this reply a whole screenshot of the full page.

MY SCREENSHOT:

BenwillLopez_0-1664363865563.png

The percentages I got are put manually, this cause the slicer to not work.

WHAT I AM TRYING TO REPLICATE WITH UPDATED DATA:

BenwillLopez_1-1664363891498.png

 

SAMPLE DATA;

KPI_SURVEY_ID|QUESTION|RATING
22PRSQ50015
23PRSQ50025
24PRSQ5003 
25PRSQ50005
26PRSQ50011
27PRSQ50021
28PRSQ5003 
29PRSQ50001
30PRSQ50012
31PRSQ50023
32PRSQ5003 
33PRSQ50005
34PRSQ50011
35PRSQ50025
36PRSQ5003 
37PRSQ50002
38PRSQ50014
39PRSQ50024
40PRSQ5003 
41PRSQ50005
42PRSQ50011
43PRSQ50021
44PRSQ5003 
45PRSQ50003
46PRSQ50014
47PRSQ50024
48PRSQ5003 
49PRSQ5003 
50PRSQ50003
51PRSQ50014
52PRSQ50025
53PRSQ5003 
54PRSQ50004
55PRSQ50011
56PRSQ50025
57PRSQ5003 
58PRSQ50001
59PRSQ50012
60PRSQ50022
61PRSQ50005
62PRSQ50011
63PRSQ50025
64PRSQ5003 
65PRSQ50005
66PRSQ50011
67PRSQ50021
68PRSQ5003 
69PRSQ50004
70PRSQ50011
71PRSQ50025
72PRSQ5003 
73PRSQ50005
74PRSQ50015
75PRSQ50025
76PRSQ5003 
77PRSQ50004
78PRSQ50004
79PRSQ50011
80PRSQ50011
81PRSQ50021
82PRSQ50021
83PRSQ5003 
84PRSQ5003 
85PRSQ50004
86PRSQ50011
87PRSQ50021
88PRSQ5003 
89PRSQ50004
90PRSQ50011
91PRSQ50021
92PRSQ5003 
93PRSQ50005
94PRSQ50011
95PRSQ50025
96PRSQ5003 
97PRSQ50003
98PRSQ50014
99PRSQ50024

Hi , @Anonymous 

Here are the steps you can refer to :

(1)This is my test data which is the same as yours:

vyueyunzhmsft_0-1664440900031.png

(2)We can create two measures :

Response = IF( HASONEVALUE('Sheet3'[RATING]), COUNT('Sheet3'[QUESTION|]) , FORMAT( DIVIDE( SUM('Sheet3'[RATING]) ,  COUNT('Sheet3'[RATING])),"0.00")  )
% = DIVIDE([Response], CALCULATE( COUNT('Sheet3'[KPI_SURVEY_ID|]), ALLSELECTED('Sheet3'[RATING]) ))

(3)Then we can put the measure and the filed we need in the Matrix visual and we will meet your need:

vyueyunzhmsft_1-1664440970957.png

If this method does not meet your needs, you can provide us with your special sample data and the desired output sample data in the form of tables, so that we can better help you solve the problem.

 

Best Regards,

Aniya Zhang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly

 

 

 

 

 

Anonymous
Not applicable

Good Morning!

 

Thanks for your reply! This mostly answers my question! I have two issues; 1. The values that are suppose to shown as percentage are shown as whole numbers 2. How may I "convert" this Matriz to the visual layout I am trying to replicate ? Is there a way to use the values of the matrix as reference for another visual ?

Picture below of the layout I am trying to replicate:

BenwillLopez_0-1664539273886.png

FILE DOWNLOAD: https://1drv.ms/u/s!AhTlVF_V8uDigYBNuw4VvHH2L0KTJg?e=NEv9m6

 

EDIT: After verifying the solution you provided resolves my question! Thanks!

Hi, @Anonymous 

The .pbix you provide i cannot open it , and i will research your problem through the introduction you provide.Can you share the .pbix to us just with oneDrive link ? And can you provide a sample output table with your sample data you provided.

 

Best Regards,

Aniya Zhang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly

 

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

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.

Top Kudoed Authors