adspace


Compare Data Reader & Dataset in ado.net?

Answer Posted / Shipra Mehrotra

DataReader and DataSet are two fundamental data containers in ADO.NET for handling relational data. Here's a comparison:nn- DataReader: It is a forward-only, read-only cursor that enables you to read data from a data source. It uses less memory compared to the DataSet since it doesn't cache the data. However, each operation requires a round trip to the database.nn- DataSet: It is a disconnected in-memory cache of data that contains multiple tables and their relationships. It can be written to XML for storage or transmission across a network. It uses more memory than DataReader due to caching but it's faster for read-write operations because it doesn't require round trips to the database.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the current version of entity framework?

1055


Explain how to call the sql commands asynchronously in ado.net version 2.0?

1004