What are basic methods of Data adapter?

 Posted by ArticlesMaint on 9/16/2009 | Category: ADO.NET Interview questions | Views: 7079

Answer: -
There are three most commonly used methods of Data adapter:-

Fill: -

Executes the Select Command to fill the Dataset object with data from the data source. It an also be used to update (refresh) an existing table in a Dataset with changes made to the data in the original data source if there is a primary key in the table in the Dataset.

FillSchema: -

Uses the SelectCommand to extract just the schema for a table from the data source, and creates an empty table in the DataSet object with all the corresponding constraints.Update:- Calls the respective InsertCommand, UpdateCommand, or DeleteCommand for each inserted, updated,or deleted row in the DataSet so as to update the original data source with the changes made to the content of the DataSet. This is a little like the UpdateBatch method provided by the ADO Recordset object, but in the DataSet it can be used to update more than one table.

Asked In: Many Interviews | Alert Moderator 

Comments or Responses

Login to post response