我使用Query控件出现了如下问题:'Error creating cursor handle'
我使用的Query如下:
ProductName := Query1.FieldByName('ProductName').Asstring;
NotDealUnit := NotDealUnit - UnitQuantity;
NotDealQuantity := QuantityPerUnit * NotDealUnit;
Query1.Close;
Query1.SQL.Clear;
Query1.SQL.Add('Update Products');
Query1.SQL.Add('SET NotDealUnit=:NotDealUnit,');
Query1.SQL.Add('NotDealQuantity=:NotDealQuantity');
Query1.SQL.Add('Where ProductName=:ProductName');
Query1.ParamByName('NotDealUnit').AsFloat := NotDealUnit;
Query1.ParamByName('NotDealQuantity').AsFloat := NotDealQuantity;
Query1.ParamByName('ProductName').AsString := ProductName;
Edit9.Text:= Query1.SQL.Text;
Query1.Active:=True;
应用系统生成以后运行,当要实现该功能时,系统发生如下错误:
Class ENoResultSet with message: 'Error Creating cursor handle'
请问该问题如何解决?