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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
ipon70
Frequent Visitor

Percentages of each hour by hour

percentage.jpg

I have a matrix as seen in the picture.  I know I can change the matrix to show me a percentage of the column but I would like/need a measure that can actually do the math.

Example: At 1:30 AM I have a total of 721 items to count.  A 191 of those items were counted at 12:00am and 143 counted at 12:30 AM.  I need to know the percentage each shift counted.

Effectively I need 191/721 and that percentage, but I need that to work on a regular table not a matrix.

 

Thank you for any help.

1 ACCEPTED SOLUTION
Syndicate_Admin
Administrator
Administrator

good

What you have to do is generate a measure that divides those numbers that you indicate using an all for the denominator...
Kind of
Measure =
VAR _numerador = TotalElements
VAR _denominador = CALCULATE(TotalItems, ALL( HOURS ) )
RETURN
DIVIDE(
_numerator
_denominator

0)
What the ALL should do is keep the 721 saved and divide the rest of the numbers with the total for each hour

View solution in original post

3 REPLIES 3
Syndicate_Admin
Administrator
Administrator

Mark it as a solution in case anyone else needs it!

Syndicate_Admin
Administrator
Administrator

good

What you have to do is generate a measure that divides those numbers that you indicate using an all for the denominator...
Kind of
Measure =
VAR _numerador = TotalElements
VAR _denominador = CALCULATE(TotalItems, ALL( HOURS ) )
RETURN
DIVIDE(
_numerator
_denominator

0)
What the ALL should do is keep the 721 saved and divide the rest of the numbers with the total for each hour

I had to modify it slightly but this worked, thank you so much.

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

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

MayPowerBICarousel

Power BI Monthly Update - May 2024

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