Re: [sqlite] Check for valid dates?

2010-08-05 Thread Simon Davies
On 5 August 2010 16:28, K Peters wrote: > Hi all, > > is there a way to check for valid ISO 8601 dates? Something like: sqlite> select case theDate like '%T%' when 1 then replace( datetime( julianday( theDate ) ),' ','T') else

Re: [sqlite] Check for valid dates?

2010-08-05 Thread Simon Slavin
On 5 Aug 2010, at 4:28pm, K Peters wrote: > is there a way to check for valid ISO 8601 dates? Use a date library to turn your date into a number (e.g. epoch, Julian day), then turn it back into a string again. If you get back the same string you start with, it's valid. Simon.

[sqlite] Check for valid dates?

2010-08-05 Thread K Peters
Hi all, is there a way to check for valid ISO 8601 dates? Thanks Kai ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users