juniorADO.NET

What is ADO.NET and what are its main components?

Updated Feb 20, 2026

Short answer

ADO.NET is a data access framework used to connect, retrieve, and manipulate data from databases using connected and disconnected architectures.

Deep explanation

ADO.NET provides two main models:

  • Connected Architecture → Uses Connection, Command, DataReader
  • Disconnected Architecture → Uses DataSet, DataAdapter

It supports multiple databases via providers like:

  • SQL Server (System.Data.SqlClient)
  • Oracle
  • MySQL

Real-world example

Fetching user data from SQL Server in a web API.

Code Example

using SqlConnection con = new SqlConnection("connection_string"); con.Open();

Common mistakes

  • Confusing DataSet vs DataReader
  • Not closing connections

Follow-up questions

No follow-up questions available yet.

More ADO.NET interview questions

View all →