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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
nok
Helper II
Helper II

Power Query show only rows with most recent date

Hello!

In PowerQuery, I'm trying to do a filter to show only the most recent files based on the column "Folder Patch.2.1", but I don't know how to do it. Here's how the data appears:
q1.PNG

In the example image above, I want to always filter ONLY the files with the "Folder Patch.2.1" column with the most recent date. In this case, it would only show these rows:
q1 - Copia.PNG


How can I do this?

1 ACCEPTED SOLUTION
mickey64
Super User
Super User

For your reference.

 

Step 0: I use these data below.

mickey64_0-1733486274908.png

 

Step 1: I click a right button of mouse on 'Folder Path.2.1' and select 'Group By...'.

mickey64_1-1733486621307.png

 

Step 2: I enter the conditions in the "Group By" window and click the OK button.

mickey64_2-1733486789144.png

 

Step 3: I expand the "Date created" column.

mickey64_3-1733486978180.png

 

Step 4: I add a condition column.

mickey64_4-1733487082408.png

mickey64_5-1733487136221.png

 

Step 5: I filter the 'Flag' column.

mickey64_6-1733487179430.png

 

Step 6: I remove these columns.

[Before]

mickey64_7-1733487300264.png

[After]

mickey64_8-1733487315504.png

 

 

View solution in original post

2 REPLIES 2
mickey64
Super User
Super User

For your reference.

 

Step 0: I use these data below.

mickey64_0-1733486274908.png

 

Step 1: I click a right button of mouse on 'Folder Path.2.1' and select 'Group By...'.

mickey64_1-1733486621307.png

 

Step 2: I enter the conditions in the "Group By" window and click the OK button.

mickey64_2-1733486789144.png

 

Step 3: I expand the "Date created" column.

mickey64_3-1733486978180.png

 

Step 4: I add a condition column.

mickey64_4-1733487082408.png

mickey64_5-1733487136221.png

 

Step 5: I filter the 'Flag' column.

mickey64_6-1733487179430.png

 

Step 6: I remove these columns.

[Before]

mickey64_7-1733487300264.png

[After]

mickey64_8-1733487315504.png

 

 

lbendlin
Super User
Super User

Click the dropdown, sort the column descending

Group by folderpath.2.1

keep top row

ungroup

Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

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

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 community update carousel

Fabric Community Update - June 2025

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