I had a tough time myself with dates. Hope the following helps. Dates are actually stored in SQLite in YYYY-MM-DD format, with leading 0 and they are stored as strings. What helped me is that I do the date comparison as is in the database - even though they are stored as strings the format is consistent, hence 2009-01-21. > 2009-01-20
If I need to display the date it is a simple matter to convert the string to MM/DD/YYYY. ------Original Message------ From: Paolo Pisati Sender: sqlite-users-boun...@sqlite.org To: General Discussion of SQLite Database ReplyTo: General Discussion of SQLite Database Sent: Jan 21, 2009 06:50 Subject: Re: [sqlite] Date datatype MikeW wrote: > > It's a string comparison, '2009/' is identical in each case > but '1/7' > '01/20' since '1' > '0' > i suspected it, ok. > See also http://www.sqlite.org/lang_datefunc.html > that page shows how to convert date in different formats: does that mean that i have first to convert the date in a unix timestamp and then do a numercial comparison? -- bye, P. _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users Timothy A. Sawyer, CISSP Managing Director MBD Solutions Phone: (603) 546-7132 Web: http://www.mybowlingdiary.com Email: tsaw...@mybowlingdiary.com _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users