Problem with SQLTimeStamp
Posted: Tue 13 Nov 2007 19:29
Hello,
I have problem with DATE=TSQlTimeStamp fields. This simple code generates exception:
var X:Variant;
X:=VarSQLTimeStampCreate(Now);
Q.SQL.Text:='insert into testa(id,datum) values (1,:D)';
Q.ParamByName('D').Value:=X;
Q.ExecSQL();
Q.SQL.Text:='update testa set id=2 where DATUM=:D';
Q.ParamByName('D').Value:=X;
r:=Q.ExecSQL();
if r=0 then raise Exception.Create('Record not found');
D2005, D2006, driver 4.20.5 OIC and NET too
Is it a problem in driver or is it a general problem of sqltimestamps?
Thanks
Zdenek
I have problem with DATE=TSQlTimeStamp fields. This simple code generates exception:
var X:Variant;
X:=VarSQLTimeStampCreate(Now);
Q.SQL.Text:='insert into testa(id,datum) values (1,:D)';
Q.ParamByName('D').Value:=X;
Q.ExecSQL();
Q.SQL.Text:='update testa set id=2 where DATUM=:D';
Q.ParamByName('D').Value:=X;
r:=Q.ExecSQL();
if r=0 then raise Exception.Create('Record not found');
D2005, D2006, driver 4.20.5 OIC and NET too
Is it a problem in driver or is it a general problem of sqltimestamps?
Thanks
Zdenek