title: Difference between two timestamps in SQLite with high precision
body: <p>I need to get the difference between two timestamps in SQLite.
  While searching, I found <a href="https://stackoverflow.com/questions/17708167/difference-in-seconds-between-timestamps-in-sqlite3">this question</a>, and while the accepted answer seems to work at first glance, it looses a lot of precision:</p>
  
  <p>Taking this query</p>
  
  <pre><code>select timestamp, EndTimeStamp, ((julianday(EndTimeStamp)-julianday(timestamp)) * 86400.0) as Duration from X
  </code></pre>
  
  <p>I get this result:</p>
  
  <pre><code>"2016-04-18 13:44:31.630916"    "2016-04-18 13:44:31.63114" "0.00100582838058472"
  "2016-04-18 13:44:31.6315231"   "2016-04-18 13:44:31.6316997"   "0.0"
  "2016-04-18 13:44:31.6320359"   "2016-04-18 13:44:31.632202"    "0.0"
  "2016-04-18 13:44:31.6326964"   "2016-04-18 13:44:31.6329361"   "0.0"
  </code></pre>
  
  <p>As you can see, the three last results have a calculated difference of Zero, but the timestamps are actually different.</p>
  
  <p><strong>Is it possible, in SQL, with the DATETIME field type, to calculate a precise difference? I would prefer to not need to fallback to C#.</strong></p>