title: Get latest date after joining with another table and grouping by some other column mysql
body: <p>I have 2 tables like this:</p>
  <p>table_1 :</p>
  <p><a href="https://i.stack.imgur.com/TLSAL.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/TLSAL.png" alt="enter image description here" /></a></p>
  <p>table_2 :</p>
  <p><a href="https://i.stack.imgur.com/Gvjmt.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Gvjmt.png" alt="enter image description here" /></a></p>
  <p>I want to join these two tables and get the latest rank of all the ids.</p>
  <p>I got upto this query:</p>
  <pre><code>SELECT a.Name, b.Rank
  FROM table_1 a
  INNER JOIN table_2 b
  ON a.id = b.id
  GROUP BY id
  </code></pre>
  <p>This gives me the rank based for each id, but not the rank on the latest date.</p>
  <p>I'm not sure how to do this. Any help is appreciated.</p>
  <p>Please note that I have 100s of different dates for same user ids in table_2, and when joined with table_1, should result in latest rank. This is my requirement.</p>