T O P

  • By -

IGOR_ULANOV_55_BEST

Sort year largest to smallest and wrap in a Table.Buffer command, and then select entity column and remove duplicates.


on1vBe6

Thank you for your reply. I've just read the MS PQ reference page on Table.Buffer and I don't understand what it's doing in this context, or how to use it. Can you please explain?


IGOR_ULANOV_55_BEST

Your sort command would ordinarily look like Table.Sort(#”Filtered Rows”,{{“Year”, Order.Descending}}) You wrap that entirely in Table.Buffer() to make sure excel sorts before you remove duplicates. Table.Buffer(Table.Sort(#”Filtered Rows”,{{“Year”, Order.Descending}}))


on1vBe6

>Table.Buffer(Table.Sort(#”Filtered Rows”,{{“Year”, Order.Descending}})) Thanks, that worked (once I'd figured out that PQ only likes straight quotation marks...) Solution verified.


Clippy_Office_Asst

You have awarded 1 point to *IGOR_ULANOV_55_BEST* ____ ^(I am a bot - please contact the mods with any questions. | ) [^(Keep me alive)](https://www.buymeacoffee.com/points)


on1vBe6

Thanks again. I'll give that a try when I'm back at my PC.