H
hnhjg
Unregistered / Unconfirmed
GUEST, unregistred user!
怎样通过sql语言实现对日期字段的赋值?谢谢大家的帮助.
请大家看看下面代码:
s:=format('update t_dz set fd_csrq=%d,fd_bzrq=%d,fd_sxrq=%d',
[DateTimePicker1.DateTime,DateTimePicker2.DateTime,
DateTimePicker2.DateTime]);
with ADOQuery1 do
begin
Close;
SQL.Clear;
SQL.Add(s);
ExecSQL;
end;
运行错误如下:
Format '%d' invalid or incompatible with argument.
请大家看看下面代码:
s:=format('update t_dz set fd_csrq=%d,fd_bzrq=%d,fd_sxrq=%d',
[DateTimePicker1.DateTime,DateTimePicker2.DateTime,
DateTimePicker2.DateTime]);
with ADOQuery1 do
begin
Close;
SQL.Clear;
SQL.Add(s);
ExecSQL;
end;
运行错误如下:
Format '%d' invalid or incompatible with argument.