Subject Re: [IBO] tiboquery & sqltimestamps
Author petegajria
hi paul,

> How about
> QueryField.AsDateTime = Now;

the above sets all the millisec times to 000
the prob is im running a sync between m$sql & an interbase db
where the timestamp on the sqlserver side is always assumed to
be correct
i tried putting in the value i get from sqlserver as datetime,
astring, asvariant, assqltimestamp & all of them failed

for datetime the ms time invariably gets set to 000
extremely annoying when theres a large number of rows with
the same date & time only the msec's differ so its critical
that the data be accurate on both sides...

anyone else running into the above scenario ?


--- In, Paul Vinkenoog <paul@v...> wrote:
> Hi petegajria,
> > im running into an issue where i need to timestamp every row in a
> > table & the timing needs to be precise down to the millisecond
> >
> > however when using tiboquery it doesnt seem to like
> > queryfield.assqltimestamp & runs into issues when i try to
> > insert/update data into the table
> >
> > anyone else run into this & is there a workaround. the field
> > up as datetime when the fields are bound at design time.
> How about
> QueryField.AsDateTime = Now;
> This works for me (at least the BCB equiv does).
> Alternatively, and if you're using Firebird on a Windows server, you
> can let the database engine do the work: define "before insert" and
> "before update" triggers for the tables concerned and have them
> GetExactTimestamp() [from FBUDF] to the fields in question.
> Greetings,
> Paul Vinkenoog