MyDAC

DADataAdapter.Fill

Adds or refreshes rows in the System.Data.DataSet to match those in the TDataSet and creates a DataTable.

Unit

Syntax

Remarks

Adds or refreshes rows in the System.Data.DataSet to match those in the TDataSet using the DataSet parameter, and creates a DataTable named tableName. Function returns the number of rows successfully inserted into DataSet.

TDataSet object associated with DADataAdapter must be valid, but it does not need to be opened. If TDataSet is closed before Fill is called, it is opened to retrieve data, then closed. If TDataSet is opened before Fill is called, it remains opened.

If an error is encountered while populating the dataset, rows added prior to the occurrence of the error remain in the dataset. The remainder of the operation is aborted.

If TDataSet does not return any rows, fields are created and no rows are added to the DataSet, and no exception is raised.

See Also

© 1997-2017 Devart. All Rights Reserved. Request Support DAC Forum Provide Feedback