Difference between Data Set and Data Reader

Data reader and data set are most common ado.net objects used in .net framework
Both are provide the facility to fetch the data from database .While there are some intresting differences and different way of working.Data reader work in a connected mode,but data set work in a disconnected mode.Data reader is read only and forward only.The execution of data reader is fast as compare to data set. So the most intresting difference between these two is that data reader cannot used for paging but data set can be used for paging.

Regards
Vivek Sharma


Comments

Author: sangeetha03 Mar 2009 Member Level: Gold   Points : 2

Data reader
1. It is a read only and forward only data.
2. U can access one table at time.
3. It can't persist the data.
4. It is comes under connected architecture.
5. One of the most advantage is it is much faster than data
adapter

Data set:

1. It is defined with multiple tables.
2. It can persist the data.
3. It is a relational data cache hosted in application
domain during execution.
4. It is a disconnected architecture.
5. It can't defined with out data adapter.



  • Do not include your name, "with regards" etc in the comment. Write detailed comment, relevant to the topic.
  • No HTML formatting and links to other web sites are allowed.
  • This is a strictly moderated site. Absolutely no spam allowed.
  • Name:
    Email: