cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
vcm2778
Helper II
Helper II

How to use countx with multiple parameter

HI Team

i do have this below table

AreaCase
SydneyReview
SydneyAccepted
MelbourneDispute
MelbourneDispute
MelbourneReview
PerthAccepted
PerthReview
SydneyDispute
PerthDispute
MelbourneReview

 

i like this way in Power Bi

KLMNOPQR
Row LabelsAccepted% completedDispute% completedReview% completedGrand Total
Melbourne L3/R32N3/R32P3/R34
Perth1L4/R41N4/R41P4/R43
Sydney1L5/R51N5/R51P5/R53
Grand Total2L6/R64 4 10

 

with countx function in Power Bi measure 

can anyone guide me. Heaps thansk i

2 ACCEPTED SOLUTIONS
Fowmy
Super User
Super User

@vcm2778 

Based on the above sample data, what exactly do you need to count? Please provide the expected result.

Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

View solution in original post

@vcm2778 

Create two measures: I attached the file below my signature.

Count = COUNTROWS(Table1)
Count % = 

DIVIDE(
    [Count],
    CALCULATE(
        [Count],
        ALLSELECTED(Table1[Case] )
    )
)

Fowmy_0-1626761191811.png

 

Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

View solution in original post

6 REPLIES 6
Fowmy
Super User
Super User

@vcm2778 

You do not need a calculation. Insert a matrix visual onto the report canvas, add the AREA to Rows section and the CASE to Column selection then insert a CASE again to the Value section and set the aggregation to COUNT 

Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

vcm2778
Helper II
Helper II

vcm2778_0-1626758541962.png

i am counting in excel by pivot table like this

vcm2778_1-1626758625915.png

 

like this

@vcm2778 

Create two measures: I attached the file below my signature.

Count = COUNTROWS(Table1)
Count % = 

DIVIDE(
    [Count],
    CALCULATE(
        [Count],
        ALLSELECTED(Table1[Case] )
    )
)

Fowmy_0-1626761191811.png

 

Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

View solution in original post

Heaps thanks mate, all good. i got what i wanted. appriciate your help 

Fowmy
Super User
Super User

@vcm2778 

Based on the above sample data, what exactly do you need to count? Please provide the expected result.

Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

View solution in original post

HI Fowmy, thanks for replying, 

I am counting how many % complted every Area by case wise. like Sydney is having 4 rows then how many % for Review, Dispute....

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

November Power BI Update 768x460.png

Check it Out!

Click here to read more about the November 2021 Updates!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Solution Authors
Top Kudoed Authors