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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
drogo96
Frequent Visitor

how to count of the count

I have a matrix with phone numbers and count of the phone numbers. Now I need to display the count of all numbers which has count of 100,99 etc .Like there may be 150 numbers with count 100. or 98 numbers with count 99 etc Screenshot (84).png 

3 REPLIES 3
drogo96
Frequent Visitor

i tried but first step is not working it gives me "The expression specified in the query is not a valid table expression." error

@drogo96 Hii

I think u are doing sth wrong. I checked and it worked. Share your pbix file.

MohammadLoran25
Super User
Super User

Hi @drogo96 ,

 

1-Create below CALCULATED COLUMN in your Table (Calculated column, Not Measure)

 

PhonNoCount =
CALCULATE (
    CALCULATE (
        COUNTROWS ( PhoneNumberTable ),
        FILTER (
            PhoneNumberTable,
            PhoneNumberTable[msisdn] = SELECTEDVALUE ( PhoneNumberTable[msisdn] )
        )
    )
)

 

 

2-Create the measure:

 

FinalMeasure =
CALCULATE (
    COUNTROWS ( VALUES ( PhoneNumberTable[msisdn] ) ),
    PhoneNumberTable[PhonNoCount] = SELECTEDVALUE ( PhoneNumberTable[PhonNoCount] )
)

 

 

3-Put the calculated column "PhoneNoCount" and "FinalMeasure" in a Table visual and get what you need.

 

It helped? Mark it as an accepted solution.
Regards,
Loran

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.