Used to contain parameters for a SQL statement.
property Params: TDAParams stored False;
Access the Params property at runtime to view and set parameter names, values, and data types dynamically (at design-time use the Parameters editor to set parameter properties). Params is a zero-based array of parameter records. Index specifies the array element to access. An easier way to set and retrieve parameter values when the name of each parameter is known is to call ParamByName.
Setting parameters at runtime:
procedure TForm1.Button1Click(Sender: TObject); begin with MySQL do begin SQL.Clear; SQL.Add('INSERT INTO Temp_Table(Id, Name)'); SQL.Add('VALUES (:id, :Name)'); ParamByName('Id').AsInteger := 55; Params[1].AsString := ' Green'; Execute; end; end;