[DUG] Delphi SQL issue

karlreynolds at xtra.co.nz karlreynolds at xtra.co.nz
Mon Feb 26 12:49:13 NZDT 2007


Maybe I misunderstood. You initially used AsDate (rather than AsDateTime) so
I assumed you didn't want the time part of the date, but in your other reply
you said:

>Time component was correct but not the date.

suggesting that you did. If you want time included then take the Trunc out.

ParamByName('DT').AsSQLTimeStamp :=
DateTimeToSQLTimeStamp(EffluentRec.DT);

Cheers,
Carl

-----Original Message-----
From: delphi-bounces at ns3.123.co.nz [mailto:delphi-bounces at ns3.123.co.nz] On
Behalf Of karlreynolds at xtra.co.nz
Sent: Monday, February 26, 2007 10:23 AM
To: 'NZ Borland Developers Group - Delphi List'
Subject: RE: [DUG] Delphi SQL issue

I've had similar problems with Date and DateTime parameters so now I use
TimeStamp instead.

ParamByName('DT').AsSQLTimeStamp :=
DateTimeToSQLTimeStamp(Trunc(EffluentRec.DT));

should work.

Cheers,
Carl


_______________________________________________
Delphi mailing list
Delphi at ns3.123.co.nz
http://ns3.123.co.nz/mailman/listinfo/delphi




More information about the Delphi mailing list