Re: [sqlite] Best way to do a date comparison?

2009-05-07 Thread Radcon Entec
Thanks again for your help, Igor. RobR ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] Best way to do a date comparison?

2009-05-07 Thread Igor Tandetnik
Radcon Entec wrote: > So, since SQLite doesn't have a dedicated date or time type, what > does the datetime() function return? Merely a string in a guaranteed > format? Yes. > I'm sure I need to use the datetime() function on both sides > of the comparison Not

Re: [sqlite] Best way to do a date comparison?

2009-05-07 Thread Radcon Entec
Igor, Thank you very much for your reply. So, since SQLite doesn't have a dedicated date or time type, what does the datetime() function return?  Merely a string in a guaranteed format?  I'm sure I need to use the datetime() function on both sides of the comparison to ensure that I'm

Re: [sqlite] Best way to do a date comparison?

2009-05-07 Thread Igor Tandetnik
Radcon Entec wrote: > I am trying to write a simple applicaton in C# that will remove all > data older than 30 days from an SQLite table. However, my application > is removing all data, not just the old data. > > Before I run my query, the value_timestamp field of my table

Re: [sqlite] Best way to do a date comparison?

2009-05-07 Thread Christopher Taylor
Before I run my query, the value_timestamp field of my table contains: 2009-05-07 17:00:43 My query is: delete from trend_data where datetime(value_timestamp) < '4/7/2009 12:37:32 PM' Your times are in different formats - -mm-dd hh-mm-ss is what you state is in the database. You should

[sqlite] Best way to do a date comparison?

2009-05-07 Thread Radcon Entec
Greetings! I am trying to write a simple applicaton in C# that will remove all data older than 30 days from an SQLite table.  However, my application is removing all data, not just the old data. Before I run my query, the value_timestamp field of my table contains: 2009-05-07 17:00:43 My