//你要賦的值
你可以這樣寫:
With ado do
Begin
Close;
Parameters.ParamByName('a').Value:=a1; //a1你要賦的值
Parameters.ParamByName('b').Value:=b1;; //b1你要賦的值
Prepared;
ExecSQL;
End;
Set Prepared before calling the Execute method
to specify whether ADO prepares the command.
If Prepared is set to True and the command component
is connected to a data store, ADO prepares
the command before executing it. If Prepared is set to False,
ADO does not prepare the command.