Forum Discussion

Rigolleto's avatar
Rigolleto
Icon for Resolver I rankResolver I
7 years ago
Solved

Using M to show the last record

 

Hi,

I need to filter and show the last record from the list, I need to do it in power query using M, anybody can help!!!

 

  • Anonymous's avatar
    Anonymous
    7 years ago

    Rigolleto - You could Add a Custom Column that indicates whether the row equals the max index, like this:

    if [Index] = List.Max(#"Added Index"[Index]) then "Yes" else "No"

    Note: #"Added Index" is the name of the previous step in my case. You'll need to use the name of your previous step.

    Then, you can filter on your new column to only include "Yes".

    Hope this helps,

    Nathan