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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

DAX Help Needed - Count of employees above median salary

I want to create a DAX measure to calculate count of employee positions whose salaries fall below the median (< median).

The median salary is in a separate table from the employee data. I am new to DAX and am having trouble creating workable DAX for this.

Any ideas or a sample DAX to solve this conundrum?

I appreciate any help.

1 ACCEPTED SOLUTION
MattAllington
Community Champion
Community Champion

Every DAX formula depends on the table structure and the relationships. It is very difficult to give you advice without understanding exactly what the tables of data look like.  It also depends on how large your data is as to what the best approach will be. If it is a relatively small data set, say less than 10 or 20,000 employees, I would suggest just take a simple approach using a many to many relationship. This can be dangerous, but it is fine as long as you do it right. 

i suggest you post some sample data

 



* Matt is an 8 times Microsoft MVP (Power BI) and author of the Power BI Book Supercharge Power BI.
I will not give you bad advice, even if you unknowingly ask for it.

View solution in original post

2 REPLIES 2
MattAllington
Community Champion
Community Champion

Every DAX formula depends on the table structure and the relationships. It is very difficult to give you advice without understanding exactly what the tables of data look like.  It also depends on how large your data is as to what the best approach will be. If it is a relatively small data set, say less than 10 or 20,000 employees, I would suggest just take a simple approach using a many to many relationship. This can be dangerous, but it is fine as long as you do it right. 

i suggest you post some sample data

 



* Matt is an 8 times Microsoft MVP (Power BI) and author of the Power BI Book Supercharge Power BI.
I will not give you bad advice, even if you unknowingly ask for it.
Anonymous
Not applicable

Thanks for your help, Matt! This is actually for someone else. I won't be given access to the Power BI file (including the relationships and table structure) unfortunately.

 

I appreciate your assistance nevertheless. Enjoy the holidays.  

 

 

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 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.