title: Saving dates and values in a SQLite database, how to replace already existing date?
body: <p>I'm writing an app for iOS 5 that let's the user save a certain value each day, <em>only one</em>. The table have an ID INTEGER PRIMARY KEY AUTOINCREMENT, DATE TEXT, VALUE INTEGER, because the research I did told me that SQLite can't save dates as dates, but as text or integers etc.</p>
  
  <p>Two problems I now have:</p>
  
  <p>1)I can't save dates as "2011-12-05", 'cause SQLite does the math and save it as "1994" even though it is text.
  2) How do I proceed if I want to INSERT OR REPLACE a row if that date (which will be the last row, hopefully) already exists in the table?</p>
  
  <p>Would appreciate it if anybody could help :)</p>