Recent

Author Topic: Again on SQLite and date times.  (Read 2407 times)

tt

  • Full Member
  • ***
  • Posts: 239
  • СЛАВА УКРАЇНІ! / Slava Ukraïni!
Re: Again on SQLite and date times.
« Reply #45 on: November 29, 2022, 10:03:20 pm »
You can create descendant of TSQLQuery where you can override virtual method GetFieldClass() and return own TField descendant which will handle AsDateTime in a special way
(you can create own TSqliteFloatField = class(FloatField) ... define there GetAsDateTime and use this new field type for REAL columns (ftFloat))
For usage you can look at fpjsondataset.

This week I am kinda busy, but next I have some more time. This hint will be very useful I am sure.
Thanks
FPC 3.2.0/Lazarus 2.0.10+dfsg-4+b2 on Debian 11.5
FPC 3.2.2/Lazarus 2.2.0 on Windows 10 Pro 21H2

 

TinyPortal © 2005-2018