title: Deleting rows older than rows in another table with same id
body: <p>I have two tables, let's say X and Y, they have same structure.</p>
  
  <p>X:</p>
  
  <pre><code>+----------+----+-------+
  | date     | id | value |
  +----------+----+-------+
  | 1.1.2019 | 1  | 1     |
  | 1.1.2019 | 2  | 1     |
  | 1.3.2019 | 3  | 1     |
  +----------+----+-------+
  </code></pre>
  
  <p>Y:</p>
  
  <pre><code>+----------+----+-------+
  | date     | id | value |
  +----------+----+-------+
  | 1.2.2019 | 1  | 1     |
  | 1.3.2019 | 2  | 1     |
  +----------+----+-------+
  </code></pre>
  
  <p>I want to delete all rows from table X that have the same ids as in table Y but have older date, so desired output would look like so:</p>
  
  <pre><code>+----------+----+-------+
  | date     | id | value |
  +----------+----+-------+
  | 1.3.2019 | 3  | 1     |
  +----------+----+-------+
  </code></pre>
  
  <p>sadly none of my code works :/</p>