title: PL/SQL to subtract two dates
body: <p>I use SQL Server 2012, and in my table I have columns <code>id</code>, <code>date</code>, <code>days</code>.</p>
  
  <p>Column <code>date</code> is formatted <code>dd-mm-yyyy</code>.</p>
  
  <p>I need PL/SQL code to fetch today date and find difference between date column and store it in days column</p>
  
  <p>Example: </p>
  
  <p>fetch today date and find difference of stored date from the table</p>
  
  <pre><code>id       date         days
  1       01-12-2015      1
  2       30-11-2015      2
  </code></pre>
  
  <p>I need PL/SQL code.</p>