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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more

Reply
alexcatala
Helper IV
Helper IV

Count only specific rows

Hi,

 

I am currently working on a formula to count the number of ratings that are >=2 and divide it against the number of applicants per store:

 

Qualified candidates =
VAR __BASELINE_VALUE =
CALCULATE(
COUNTA('Application Report'[Average rating]),
'Application Report'[Average rating] >=2
)
VAR __MEASURE_VALUE = sum('Job Report'[Number of Applications])
RETURN
DIVIDE( __BASELINE_VALUE,__MEASURE_VALUE )

 

 

DATA:

Application Report:

StoreAverage Rating
7023.00
7022.50

104

3.00

104

1.50

705

1.00

 

Job Report:

StoreNumber of Applications
70245
70525
10430

 

Unfortunately, I couldn't find a way to count them and be able to filter them per store.

 

I hope it makes sense.

 

Thanks for your support.

1 ACCEPTED SOLUTION
v-yalanwu-msft
Community Support
Community Support

Hi, @alexcatala ;

Hi, @alexcatala ;

Try it.

 

Qualified candidates = 
VAR __BASELINE_VALUE =
    CALCULATE (
        SUM( 'Application Report'[Average rating] ),FILTER('Application Report',
        [Average rating] >= 2))
VAR __MEASURE_VALUE =
    SUM ( 'Job Report'[Number of Applications] )
RETURN
    DIVIDE ( __BASELINE_VALUE, __MEASURE_VALUE )
 

 

The final show:

AilsaTao_1-1661141721109.png

or can you share desired result,  which could let me understand your logic?

If the above one can't help you get the desired result, please provide some sample data in your tables (exclude sensitive data) with Text format and your expected result with backend logic and special examples. It is better if you can share a simplified pbix file. You can refer the following link to upload the file to the community. Thank you.

How to upload PBI in Community


Best Regards,
Community Support Team _ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
v-yalanwu-msft
Community Support
Community Support

Hi, @alexcatala ;

Hi, @alexcatala ;

Try it.

 

Qualified candidates = 
VAR __BASELINE_VALUE =
    CALCULATE (
        SUM( 'Application Report'[Average rating] ),FILTER('Application Report',
        [Average rating] >= 2))
VAR __MEASURE_VALUE =
    SUM ( 'Job Report'[Number of Applications] )
RETURN
    DIVIDE ( __BASELINE_VALUE, __MEASURE_VALUE )
 

 

The final show:

AilsaTao_1-1661141721109.png

or can you share desired result,  which could let me understand your logic?

If the above one can't help you get the desired result, please provide some sample data in your tables (exclude sensitive data) with Text format and your expected result with backend logic and special examples. It is better if you can share a simplified pbix file. You can refer the following link to upload the file to the community. Thank you.

How to upload PBI in Community


Best Regards,
Community Support Team _ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

amitchandak
Super User
Super User

@alexcatala , Create a common store dimension and use that to display this formula 

 

refer

https://amitchandak.medium.com/power-bi-when-i-asked-you-to-create-common-tables-a-quick-dax-solutio...

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Hi @amitchandak ,

 

I have already a common table, such as a store and data table. 

 

What I need is a formula to give me the percentage of the average rating bigger than 2 divided with the number of applicants.

 

I have tried with the If formula but only 1 option can be given and I need all numbers from 2 to 5 to be included.

 

I used it before to filter a specific value  ( text) but now I need to filter several values (whole number).

 

Any advice?

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.