FR4 + Delphi + ADO + PostgreSQL timestamps

Hello everyone,

I'm just starting with FR4 and i find it very powerful. I'm facing some issues though.
We have a Delphi (2006) application with FR4.
I load a report and pass date variables.

In my PosgreSQL DB my date fields are 'TimeStamp without timezone' typed.
I tried passing my variables as TDateTime, TimeStamp, String.
Nothing seems to work. I can see correctly the variable values but when i want to filter with them in an TADOQuery SQL (ex ' myTable.myDateField > my variable ') it doesn't work.

Does anyone already have to deal with timestamp field in postgres?

Thanks

Comments

  • edited 9:19AM
    Have you tried to use casting the date or column value?
  • edited 9:19AM
    technisoft wrote: »
    Have you tried to use casting the date or column value?

    In my query? I tried but maybe my syntax is wrong. How would you write it?
  • edited 9:19AM

    In my query? I tried but maybe my syntax is wrong. How would you write it?

    In Firebird it would be (I have no experience with PostGreSQL)

    CAST( <column> AS <DATATYPE> ) AS <castedColumn>

    e.g.

    CAST( DATE_TIME_STAMP_COLUMN AS DATE ) AS DATE_ONLY

Leave a Comment