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! Request now

Reply
Anonymous
Not applicable

When you removed duplicates from a table, which record does it keep?

I have a dimension table and sometimes a duplicate creeps in so I have a de-dup step. However, is it keeping the top-most record? Or bottom? Or is there other logic involved?

 

I ask because, if I filter date descending so I have the most recent records at the top, then de-dupe, can I safely tell my customers they are seeing the most recent version of that record? 

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Anonymous , I think you need to follow this approach

https://exceleratorbi.com.au/remove-duplicates-keep-last-record-power-query/

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

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Ahh fabulous @amitchandak - table.buffer to force a sort by, or grouping my max date! How could I have overlooked this option. Thanks this article was exactly what I needed.

amitchandak
Super User
Super User

@Anonymous , I think you need to follow this approach

https://exceleratorbi.com.au/remove-duplicates-keep-last-record-power-query/

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

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

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!

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.

Top Solution Authors
Top Kudoed Authors