Define DataAdapter in ADO.Net?
DataAdapter object is links the database and a Connection object with the ADO.NET-managedDataSet object through its SELECT and action query Commands. Means it works like a bridge DataAdapter specified that which data is to move into and out of the DataSet. DataAdapter provide references to SQL statements or stored procedures that are invoked to read or write to a database.
The DataAdapter provides four properties that allow us to control how updates are made to the server:
Define the ways to populate a Dataset in ADO.Net?
There are following way to populate Dataset:
a.By using DataAdapter objects and Fill method.
b.By creating DataTable, DataColumn and DataRow objects programmatically.
c.Read an XML document or stream into the DataSet.
d.Merge (copy) the contents of another DataSet, with the Merge method.
Define types of Datasets in ADO.Net?
There are two type of dataset in Ado.net:
1.Typed DataSet: Typed DataSet is derived from the base DataSet class and then uses information in an XML Schema file (.xsd file) in order to generate a new class.
Create a typed DataSet without designer - manually
a.Call the command prompt (cmd) at the location of the XSD schema file.
b.Use the XSD.EXE utility to create the class for the typed DataSet.
2.Untyped DataSet : Untyped DataSet is not defined by a schema, instead, you have to add tables, columns and other elements to it yourself, either by setting properties at design time or by adding them at run time.
Define Dataset in ADO.Net?
1.Disconnected Recordset objects similar to an array.
2.Supports disconnected data access and operations.
3.Scalability, Provide greater scalability because users no longer have to be connected to the database all the time.
DataSet object is made up of two objects:
1.DataTableCollection object containing null or multiple DataTable objects
2.DataRelationCollection object containing null or multiple DataRelation objects which establish a parent/child relation between two DataTable objects.
Define Data Provider in ADO.NET?
Data Provider is a set of components including:
1.The Connection object (SqlConnection, OleDbConnection, OdbcConnection, OracleConnection)
2.The Command object (SqlCommand, OleDbCommand, OdbcCommand, OracleCommand)
3.The DataReader object (SqlDataReader, OleDbDataReader, OdbcDataReader, OracleDataReader)
4.The DataAdapter object (SqlDataAdapter, OleDbDataAdapter, OdbcDataAdapter, OracleDataAdapter).
DataSet object represents a disconnected cache of data which is made up of DataTables and DataRelations that represent the result of the command.
Tell me about ADO.NET Classes?
The ADO.NET classes are found in System.Data.dll and are integrated with the XML classes in System.Xml.dll. ADO.NET is a set of classes that expose data access services to the .NET developer. There are two central components of ADO.NET classes: the DataSet, and the .NET Framework Data Provider.Reply
Define ADO.NET provides data access services in the Microsoft .NET platform?
ADO.NET to access data by using the new .NET Framework data providers which are given below:
1.Data Provider for SQL Server (System.Data.SqlClient)
2.Data Provider for OLEDB (System.Data.OleDb)
3.Data Provider for ODBC (System.Data.Odbc).
4.Data Provider for Oracle (System.Data.OracleClient).
Explain ADO.NET Namespaces?
The System.Data is main namespace of ADO.Net and it has DataSet and classes (DataTable, DataColumn, DataRow, DataRelation, Constraint,etc ). System.Data has a namespace System.Data.Common.Reply
Write a sample example of ADO.Net?
// Step 1.Open Database Connection
OleDbConnection conn = new
// Step 2.Connection database opened
// Step 3.Create DataSet and Command objects
OleDbCommand cmd = new OleDbCommand(
"SELECT * FROM empr4r",
// Step 4.Execute the command
// Step 5.Closed this connection
Give Short History of ADO.Net.
Microsoft developed ActiveX Data Objects (ADO) as a COM( Component Object Model ) wrapper around OLE DB for Databases.Reply