cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
srkase
Helper IV
Helper IV

CALCULATE PERCENTAGE

Hi 

 

I have created a matrix table in the following manner

 

branchproductspares%   
chennai10000500?   
       
  ? I want to create the percentage of spares on 10000

 

I have kept all the data in a single table... differentiated by category... category consists of product , spares and cable.

 

Kindly guide me... and thanks in advance

 

1 ACCEPTED SOLUTION
Mariusz
Super User II
Super User II

Hi @srkase 

 

Try this.

% of Spares = 
VAR _products = CALCULATE(
    SUM( YourTable[TOTAL QTY] ), 
    YourTable[CATEGORY] = "PRODUCT"
)
VAR _spares = CALCULATE(
    SUM( YourTable[TOTAL QTY] ), 
    YourTable[CATEGORY] = "SPARES"
)
RETURN DIVIDE( _spares, _products )

 

Best Regards,
Mariusz

If this post helps, then please consider Accepting it as the solution.

Please feel free to connect with me.
Mariusz Repczynski

 

View solution in original post

6 REPLIES 6
Mariusz
Super User II
Super User II

Hi @srkase 

 

Try this.

% of Spares = 
VAR _products = CALCULATE(
    SUM( YourTable[TOTAL QTY] ), 
    YourTable[CATEGORY] = "PRODUCT"
)
VAR _spares = CALCULATE(
    SUM( YourTable[TOTAL QTY] ), 
    YourTable[CATEGORY] = "SPARES"
)
RETURN DIVIDE( _spares, _products )

 

Best Regards,
Mariusz

If this post helps, then please consider Accepting it as the solution.

Please feel free to connect with me.
Mariusz Repczynski

 

View solution in original post

thanks a lot..

 

I have added drill down also..  how to calculate the drill down percentage for unit-id?

 

Mariusz
Super User II
Super User II

Hi @srkase 


Please can you provide a data sample?

Best Regards,
Mariusz

Please feel free to connect with me.
Mariusz Repczynski

 

 

how to send the sample to you?

Hi @srkase 


You can create a sample table in excel and paste it here.

 

Best Regards,
Mariusz

Please feel free to connect with me.
Mariusz Repczynski

 

YEARSHORTNAMEDEALERTYPEMAJOR GROUPMINOR GROUPSUB GROUPPRODUCTVARIANTAPRMAYJUNJULAUGSEPOCTNOVDECJANFEBMARTOTAL QTYTOTALVALPTA_DESTINATIONUNIT_CODEPTA_DISTRICTPTA_TALUKPTA_PINACP_ENTRYDTHPPERAPR VALMAY VALJUN VALJUL VALAUG VALSEP VALOCT VALNOV VALDEC VALJAN VALFEB VALMAR VALTOTAL CRDLR NAME_DESTDEST_DST_PINDST_DEST_PINPIN_DEST_DSTCATEGORY
20172018TCR4STDSUBMERSIBLES6" SETEMS+ESRSEMS7MS + ESRS31-2333AAA + 13FAA100000000000115000VADAKKENCHERRYASE1PALAKKADALATHUR678683########7.500000000000000CHANS ELECTRICALS VADAKKENCHERRYVADAKKENCHERRY PALAKKAD 678683PALAKKAD VADAKKENCHERRY 678683678683VADAKKENCHERRY PALAKKADPRODUCT
20172018TCR5STDSUBMERSIBLES6" SETEMS+ESRSEMS5MS + ESRS31-1533AAA + 13FAA100000000000115000SULTHAN BATHERYASE1WAYANADSULTHANBATHERY673592########500000000000000GRANPA MARKETING CORPORATION SULTHAN BATHERYSULTHAN BATHERY WAYANAD 673592WAYANAD SULTHAN BATHERY 673592673592SULTHAN BATHERY WAYANADPRODUCT
20182019TCR6STDSUBMERSIBLES6" SETEMS+ESRSEMS7MS + ESRS51-0833AAA + 13FAA100000000000115000KOZHINJAMPARAASE1PALAKKADCHITTUR678555########7.500000000000000VISHNU ELECTRICALS KOZHINJAMPARAKOZHINJAMPARA PALAKKAD 678555PALAKKAD KOZHINJAMPARA 678555678555KOZHINJAMPARA PALAKKADPRODUCT
20192020TCR8STDSUBMERSIBLES6" SETEMS+ESRSEMS5MS + ESRS42-1033AAA + 13FAA100000000000115000VADAKKENCHERRYASE1PALAKKADALATHUR678683########500000000000000CHANS ELECTRICALS VADAKKENCHERRYVADAKKENCHERRY PALAKKAD 678683PALAKKAD VADAKKENCHERRY 678683678683 VADAKKENCHERRY PALAKKADPRODUCT
20192020TCR9STDSUBMERSIBLES6" SETEMS+ESRSEMS5MS + ESRS36-1233AAA + 13FAA100000000000115000PAZHAYANNURASE1THRISSURTHALAPILLY680587########500000000000000GUARANTY PUMPS & BOREWELLS PAZHAYANNURPAZHAYANNUR THRISSUR 680587THRISSUR PAZHAYANNUR 680587680587 PAZHAYANNUR THRISSURPRODUCT
20182019TCR10STDSUBMERSIBLES6" SETST+RS-SST075D + RS31SS/3031AAA + 21FAA100000000000115000KOTTAYAMASE1KOTTAYAMKOTTAYAM686001########1000000000000000KOTTAYAM MOTOR HOUSE KOTTAYAMKOTTAYAM KOTTAYAM 686001KOTTAYAM KOTTAYAM 686001686001KOTTAYAM KOTTAYAMPRODUCT
20172018TCR15STDSPARESSPARESSPARESIMPELLER HCS725H / ASMSP725H (SS) (SP)00000000500051900SULTHAN BATHERYASE2WAYANADSULTHANBATHERY673592######## 00000000000000GRANPA MARKETING CORPORATION SULTHAN BATHERYSULTHAN BATHERY WAYANAD 673592WAYANAD SULTHAN BATHERY 673592673592     SULTHAN BATHERY                                              WAYANADSPARES
20172018TCR16STDSPARESSPARESSPARESIMP+DIFF ASSY JRF06 (SPS)0000000045000452000MANANTHAVADYASE4WAYANADMANANTHAVADY670645######## 00000000000000KUZHIKANDATHIL PLUMPING&ELECTRICALS MANANTHAVADYMANANTHAVADY WAYANAD 670645WAYANAD MANANTHAVADY 670645670645     MANANTHAVADY                                                 WAYANADSPARES
20172018TCR17STDSPARESSPARESSPARESIMP+DIFF ASSY JRF09 (SPS)0000000045000452100MANANTHAVADYASE4WAYANADMANANTHAVADY670645######## 00000000000000KUZHIKANDATHIL PLUMPING&ELECTRICALS MANANTHAVADYMANANTHAVADY WAYANAD 670645WAYANAD MANANTHAVADY 670645670645     MANANTHAVADY                                                 WAYANADSPARES
20182019TCR19STDSPARESSPARESSPARESDIFFUSER HOUSING RS30/35/40 (SPS)0000000012000122300KOTTAYAMASE1KOTTAYAMKOTTAYAM686001######## 00000000000000KOTTAYAM MOTOR HOUSE KOTTAYAMKOTTAYAM KOTTAYAM 686001KOTTAYAM KOTTAYAM 686001686001     KOTTAYAM                                                     KOTTAYAMSPARES
20182019TCR20STDSPARESSPARESSPARESPAN HEAD SCREW MS M5 X 16 MM (SP)000000001000001002400QUILANDYASE2KOZHIKODEKOYILANDI673305######## 00000000000000COSMOS ELECTRICALS QUILANDYQUILANDY KOZHIKODE 673305KOZHIKODE QUILANDY 673305673305     QUILANDY                                                     KOZHIKODESPARES

Helpful resources

Announcements
MBAS on Demand

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

July 2021 Update 768x460.png

Check it out!

Click here to read more about the July 2021 Updates

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

Urdu Hindi D365 Bootcamp 768x460.png

Urdu Hindi D365 Bootcamp

Dont miss our very own April Dunnam’s The Developer Guide to the Galaxy! Find out what the Power Platform has to offer for the traditional developer.

Top Solution Authors
Top Kudoed Authors