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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
Syndicate_Admin
Administrator
Administrator

Calculate Percentage on Columns

Dear

I have the following table (visual), I have data from the "Ranking, Total Events, No Count, and Yes Count" columns.

This data varies with date filtering.

I need to get the "Yes Percentage" column, as shown in the attached table, calculated as: " (Yes Account)*100/(No Account) .

In the "Total" row, I need you to enter the total percentage over total events, not the average of the percentages in the same column.

Please help with how to implement the solution.

Best regards

ClassificationTotal EventsAccount NoAccount YesPercentage Yes
A31267%
B303100%
C1611594%
D101100%
Total2322191%
1 ACCEPTED SOLUTION
v-xinruzhu-msft
Community Support
Community Support

Hi @Syndicate_Admin 

You can create a measure

Measure =
SUMX (
    VALUES ( 'Table'[Classification] ),
    DIVIDE ( SUM ( 'Table'[Account Yes] ), SUM ( 'Table'[Total Events] ) )
)

Output

vxinruzhumsft_0-1699336175058.png

 

Best Regards!

Yolo Zhu

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

2 REPLIES 2
v-xinruzhu-msft
Community Support
Community Support

Hi @Syndicate_Admin 

You can create a measure

Measure =
SUMX (
    VALUES ( 'Table'[Classification] ),
    DIVIDE ( SUM ( 'Table'[Account Yes] ), SUM ( 'Table'[Total Events] ) )
)

Output

vxinruzhumsft_0-1699336175058.png

 

Best Regards!

Yolo Zhu

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

Data-estDog
Resolver II
Resolver II

Try this:

DataestDog_0-1699017779097.png

Dax: 

PercentYes = DIVIDE(SUMX(Class,Class[YesAccount]), SUMX(Class, Class[TotalEvents]))
 
Be sure to mark as the solution and thumbs up if I help you!

Helpful resources

Announcements
July 2024 Power BI Update

Power BI Monthly Update - July 2024

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

PBI_Carousel_NL_June

Fabric Community Update - June 2024

Get the latest Fabric updates from Build 2024, key Skills Challenge voucher deadlines, top blogs, forum posts, and product ideas.

Top Solution Authors