What is Connected and Disconnected Architecture in ADO.NET?
Connected Architecture in ADO.NET:
1. In the connected architecture, connection with a data source is kept open constantly for data access as well as data manipulation operations.
2. The ADO.NET Connected Architecture considers mainly three types of objects:
- SqlConnection con
- SqlCommand cmd
- SqlDataReader dr
Disconnected Architecture in ADO.NET:
1. Disconnected is the main feature of the .NET framework ADO.NET contains various classes that support this architecture. The .NET application doesn’t always stay connected with the database. The classes are designed in a way that they automatically open and close the connection. The data is stored client-side and it is updated in the database whenever required.
2. The ADO.NET Disconnected Architecture considers primarily four types of objects:
- DataSet ds
- SqlDataAdapter da
- SqlConnection con
- SqlCommandBuilder bldr