title: How can I subtract two row's values within same column using sql query?
body: <p>I want to display the <code>subtraction</code> of two values from <code>two</code> different rows using a <code>SQL</code> query.</p>
  
  <p>This is the table structure:</p>
  
  <pre><code>------------------------------------
  id | name | sub1 | sub2 | date
  ------------------------------------
  1  | ABC  | 50   | 75   | 2014-11-07
  2  | PQR  | 60   | 80   | 2014-11-08  
  </code></pre>
  
  <p>I want to subtract date 2014-11-08 subject marks from date 2014-11-07. </p>
  
  <p>Output should be like as</p>
  
  <pre><code>| sub1  | sub2 |
   ---------------
  |   10  |   5  |
  </code></pre>