Page 1 of 1

trouble accessing Date field

Posted: Thu 18 Oct 2012 05:19
by Eiichiro Kamiya
I am trying sqlite, and have a trouble accessing DateTime field.
With sqlite3.exe, the field shows proper date value, but in delphi any date value becomes '1899/12/30'.
Very similar programs for Firebird have no problem of this kind.
Any advice please.

configuration : WindowsXP, Delphi2010, sqlite3, Devart sqlite DAC(tryal)

Re: trouble accessing Date field

Posted: Thu 18 Oct 2012 08:21
by AlexP
hello,

To solve the problem, you need to specify correct date format, for example:

Code: Select all

  LiteConnection1.Options.DateFormat = 'dd.mm.yyyy';

Re: trouble accessing Date field

Posted: Sat 20 Oct 2012 02:04
by Eiichiro Kamiya
TSQLConnection does not have Options property.
I added "DateFormat = 'dd.mm.yyyy'" to Params list, but it did not change the matter.

Re: trouble accessing Date field

Posted: Tue 23 Oct 2012 08:48
by AlexP
hello,

Our VCL LiteDAC components include these options, and the options are not implemented in dbExpress driver for SQLite yet. We will review the possibility to implement this functionality in one of the next versions.

Re: trouble accessing Date field

Posted: Tue 06 Nov 2012 10:14
by mtbf40
Hello,

click on the Link...
http://www.sqlite.org/datatype3.html#datetime - 1.2 Date and Time Datatype