cancel
Showing results for
Did you mean:

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Helper III

## Measure of percentage of grand total

Hallo,

Could you please help me with a simple measure to calculate the percentage of each fraction, as it in the last column?

1 ACCEPTED SOLUTION
Community Support

Hi, @TatyDo

You may use the following measure.

``````Result =
DIVIDE(
SUM('Table'[Value]),
CALCULATE(
SUM('Table'[Value]),
ALLSELECTED('Table')
)
)``````

Result:

Best Regards

Allan

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

9 REPLIES 9
Super User

Hi,

Assuming Value is a measure that you have written, try this measure

=[Value]/CALCULATE([Value],ALL(Data[ID]))

Hope this helps.

Regards,
Ashish Mathur
http://www.ashishmathur.com
Community Support

Hi, @TatyDo

Based on my research, you may create a measure as follows.

``````Result =
DIVIDE(
SUM('Table'[Value]),
CALCULATE(
SUM('Table'[Value]),
ALL('Table')
)
)``````

or

``````Result2 =
SUMX(
'Table',
DIVIDE(
'Table'[Value],
CALCULATE(
SUM('Table'[Value]),
ALL('Table')
)
)
)``````

Then you may make the measure selected, go to 'Modeling' ribbon, click '%' and set 'Decimal places' as 0.

Result:

Best Regards

Allan

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

Helper III

The only problem I am having is that the value is not responding to the filters. You can see below what I mean.

Community Support

Hi, @TatyDo

You may use the following measure.

``````Result =
DIVIDE(
SUM('Table'[Value]),
CALCULATE(
SUM('Table'[Value]),
ALLSELECTED('Table')
)
)``````

Result:

Best Regards

Allan

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

Helper III

Thank you! 🙂

Super User

Try like

``divide(sum(table[Value]),calculate(sum(table[Value]),all(Table)))``

Super User

The above is for a Table visualization.

If you need a column in a table:

``Column = DIVIDE([Value],SUMX('Table',[Value]),0)``

@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...
Community Champion

Hi @TatyDo

try a measure

``````Measure =
DIVIDE( SELECTEDVALUE(Table[Value]),
CALCULATE(SUM(Table[Value]), ALL(Table))
)``````

or just set parameter "Show value as - Percent of Grand Total" in visual value settings

do not hesitate to give a kudo to useful posts and mark solutions as solution
Super User

In the Values area, click the drop down and then Show As and then Percent of ...

@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

Announcements

#### New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

#### Fabric Monthly Update - May 2024

Check out the May 2024 Fabric update to learn about new features.

#### Fabric certifications survey

Certification feedback opportunity for the community.

Top Solution Authors
Top Kudoed Authors