Totel:37 Click:
1
2 3 4 5 6 7 8
ADO.net Interview Questions And Answers
Page 1
Questions 1 Why ADO.NET?
Answer
ADO.NET is data access layer
Answer
We create a connection for database after that we queried the information from database.
Answer
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.
Answer
ADO stands for ActiveX Data Object .ADO.NET is an object-oriented set of libraries that allows to interact with data sources. The data source is a database, but it could also be a text file, an Excel spreadsheet, or an XML file.ADO .NET consists of classes that allow a .NET application to connect to the data source, executes commands and manage disconnected data. One of the key Differences between ADO.NET and other database technologies is how it deals with Challenge with different data sources, that means, the code you use to connect to an SQL Database will not differ that much to the one connecting to an Oracle Database.
Questions 2 What is full name of ADO.NET?
Answer
ActiveX Data Objects
Questions 3 Give Short History of ADO.Net.
Answer
Microsoft developed ActiveX Data Objects (ADO) as a COM( Component Object Model ) wrapper around OLE DB for Databases.
Questions 4 Why ADO.NET Is a Better Data Access Layer than others?
Questions 5 Write a sample example of ADO.Net?
Answer
using System;
using System.Data;
using System.Data.OleDb;
// Step 1.Open Database Connection
OleDbConnection conn = new
OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\\inventory\\inventory\\db\\invent.mdb;");
// Step 2.Connection database opened
conn.Open();
// Step 3.Create DataSet and Command objects
OleDbCommand cmd = new OleDbCommand(
"SELECT * FROM empr4r",
conn);
// Step 4.Execute the command
cmd.ExecuteScalar();
// Step 5.Closed this connection
conn.Close();
Answer
using System;
using System.Data;
using System.Data.OleDb;
// Step 1.Open Database Connection
OleDbConnection conn = new OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\\inventory\\inventory\\db\\invent.mdb;");
// Step 2.Connection database opened
conn.Open();
// Step 3.Create DataSet and Command objects
OleDbCommand cmd = new OleDbCommand(
"SELECT * FROM empr4r",
conn);
// Step 4.Execute the command
cmd.ExecuteScalar();
// Step 5.Closed this connection
conn.Close();
Goto Page:
1
2 3 4 5 6 7 8
ADO.net Objective Questions And Answers
ADO.net Objective Questions And Answers
ADO.net Interview Questions And Answers
ADO.net Interview Questions And Answers
R4R,ADO.net Objective, ADO.net Subjective, ADO.net Interview Questions And Answers,ADO.net,ADO.net Interview,ADO.net Questions ,ADO.net Answers