title: PowerQuery - Finding Most Recent Date Based on Given Value and Current Date
body: <p>I have a table called 'Table1' which has two columns being 'Name' and 'Date'.</p>
  
  <p>In Power Query Editor, I want to create a custom column called 'Last Date' to find the most recent date when the given Name appeared last time.</p>
  
  <p>For instance, B firstly appeared on 5/7/2019, then on 11/8/2019, and last on 17/9/2019. So the Last Date for B when the Date is 11/8/2019 is 5/7/2019, and the Last Date for B when the Date is 17/9/2019 is 11/8/2019. Please see below example.</p>
  
  <p><a href="https://i.stack.imgur.com/LgkWP.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/LgkWP.png" alt="enter image description here"></a></p>
  
  <p>I did some research online but got confused with custom function, VAR, Measure, MAXX, CALCULATE, FILTER, etc...</p>
  
  <p>I am not familiar with DAX nor Advanced DAX Editor so if possible please provide detailed answer or clear steps of how to apply your solution.</p>
  
  <p>Let me know if I did not make myself clear. Otherwise your prompt help is greatly appreciated!!</p>