S sutao01 Unregistered / Unconfirmed GUEST, unregistred user! 2008-03-01 #1 我在程序运行时执行SQL的Delete语句时总是提示“CommandText Does not return a result set”的错误,请问应如何解决?
深 深邃眼眸 Unregistered / Unconfirmed GUEST, unregistred user! 2008-03-01 #4 with query1 do<br>begin<br> close;<br> sql.clear;<br> sql.add('delete from tableA where 1=1 ');<br> execute;<br>end;
with query1 do<br>begin<br> close;<br> sql.clear;<br> sql.add('delete from tableA where 1=1 ');<br> execute;<br>end;
深 深邃眼眸 Unregistered / Unconfirmed GUEST, unregistred user! 2008-03-01 #5 更改:<br>with query1 do<br>begin<br> close;<br> sql.clear;<br> sql.add('delete from tableA where 1=1 ');<br> ExecSQL;<br>end;
更改:<br>with query1 do<br>begin<br> close;<br> sql.clear;<br> sql.add('delete from tableA where 1=1 ');<br> ExecSQL;<br>end;
P PING-Delphi Unregistered / Unconfirmed GUEST, unregistred user! 2008-03-04 #7 LZ用ExecSQL就行了,前些日子刚碰到。
Z zenghongqing Unregistered / Unconfirmed GUEST, unregistred user! 2008-03-04 #8 begin<br> Query1.close;<br> Query1.sql.clear;<br> Query1.sql.add('delete from tableA where 1=1 ');<br> Query1.ExecSQL;<br>end;
begin<br> Query1.close;<br> Query1.sql.clear;<br> Query1.sql.add('delete from tableA where 1=1 ');<br> Query1.ExecSQL;<br>end;