title: Update rows that have the same values in two columns in MSSQL
body: <p>My table have the same values in two columns. I would like to update only one row where in column <code>login</code> and <code>email</code> are the same value and <code>data modification</code> is earlier. So, in this example below it must update only one row with <code>ID = 2</code>. What SQL statement should I use?</p>
  
  <pre><code>ID | login   |email                |data modification
  ---|---------|---------------------|-----------------
  1  | abc     |john@mail.com        |   2017-01-10
  2  | abc     |john@mail.com        |   2017-02-14
  3  | example |john123@hotmail.com  |   2017-02-17
  </code></pre>