Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on Apr 28th, 2012  |  syntax: None  |  size: 0.30 KB  |  hits: 15  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. Compare times in SQLite
  2. SELECT strftime('%H', 'now');
  3.        
  4. SELECT strftime('%H', columnName);
  5.        
  6. String time1 = 0;
  7. String time2 = 12;    
  8. String query = "select timestamp from table where strftime('%H',timestamp) < " +
  9.        time1 +
  10.        " and strftime('%H',timeStamp) < " +
  11.        time2 +
  12.        ";";