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

Next up in the FabCon + SQLCon recap series: The roadmap for Microsoft SQL and Maximizing Developer experiences in Fabric. All sessions are available on-demand after the live show. Register now

Reply
Anonymous
Not applicable

Filter for max value based upon another column

Hi,

 

I would like to filter for the max value in one column based upon another column which is a project name over a range of time.

 

Basically I want to find the max total employees for each project which has multiple entries and create a new table with just the max value for each project

 

 PowerBi help.JPG

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

Hi @Anonymous ,

 

One sample for your reference. Here we can create a calculated column as below to work on it.

 

max total = CALCULATE(MAX(Table1[Total Employees]),FILTER(Table1,Table1[Project name]=EARLIER(Table1[Project name])))

Capture.PNG

 

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

View solution in original post

3 REPLIES 3
v-frfei-msft
Community Support
Community Support

Hi @Anonymous ,

 

One sample for your reference. Here we can create a calculated column as below to work on it.

 

max total = CALCULATE(MAX(Table1[Total Employees]),FILTER(Table1,Table1[Project name]=EARLIER(Table1[Project name])))

Capture.PNG

 

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.
Anonymous
Not applicable

thank you very much

edhans
Community Champion
Community Champion

In Power Query

 

  1. select the Project Name column
  2. Select Group By on the home tab
  3. Name the column - "Max of Employee Count" for example.
  4. Select MAX for the operation
  5. Select the Total Employees column.

The load that into the data model.



Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

DAX is for Analysis. Power Query is for Data Modeling


Proud to be a Super User!

MCSA: BI Reporting

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.