Datareader:- DataReader provides forward-only and read-only access to data. - Datareader is connected architecture - Datareader can not persist data.Dataset:1. Disconnected. 2. Can traverse data in any order front, back. 3. Data can be manipulated within the dataset. 4. More expensive than datareader as it stores multiple rows at the same time.
Following are some major differences between dataset and datareader :- 1) DataReader provides forward-only and read-only access to data, while the DataSet object can hold more than one table (in other words more than one rowset) from the same data source as well as the relationships between them. 2)Dataset is a disconnected architecture while datareader is connected architecture. 3)Dataset can persist