Difference in ADO and ADO.Net – Interview Question

Following are the basic difference between the ADO and ADO.Net in Microsoft .Net framework.

ADO.Net
ADO.Net

  1. Fundamentally we can say that ADO works in Connected environment whereas ADO.Net works in Disconnected environment.
  2. In ADO, the in memory representation of data is “Recordset“, whereas in ADO.Net the in memory representation of data is “DataSet“.
  3. Recordset contains only one table, but ti get the data from multiple tables JOINTS must be used.
  4. DataSet contains one or more than one Table. The tables between Dataset are Known as “DataTable“.
  5. In ADO, data can be accessed sequencialy with the help of RecordSet Object by using “MoveNext” method.
  6. In ADO.Net, the records are present in table and therefore it can be accessed like any other collection by iterating over it or by using Primary key index.
  7. In ADO.NET you open connections only long enough to perform a database operation, such as a Select or Update. You can read rows into a dataset and then work with them without staying connected to the data source. In ADO the recordset can provide disconnected access, but ADO is designed primarily for connected access.
  8. There is one significant difference between disconnected processing in ADO and ADO.NET. In ADO you communicate with the database by making calls to an OLE DB provider. In ADO.NET you communicate with the database through a data adapter (an OleDbDataAdapter, SqlDataAdapter, OdbcDataAdapter, or OracleDataAdapter object), which makes calls to an OLE DB provider or the APIs provided by the underlying data source.
  9. Transmitting an ADO.NET dataset between applications is much easier than transmitting an ADO disconnected recordset. To transmit an ADO disconnected recordset from one component to another, you use COM marshalling. To transmit data in ADO.NET, you use a dataset, which can transmit an XML stream.

for further read, refer this URL.

Posted

in

,

by

Tags:


Related Posts

Comments

One response to “Difference in ADO and ADO.Net – Interview Question”

  1. MOHIT TYAGI Avatar
    MOHIT TYAGI

    i want notes

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Discover more from Jitendra Zaa

Subscribe now to keep reading and get access to the full archive.

Continue Reading