You are on page 1of 3

Interview Questions of ADO.

NET

www.twoengineers.co.in
1.) Which namespace do you include while using ODBC connectivity?
System.Data.ODBC.

2.) How many objects does ADO.net have and what are they?

ADO.net has 5 objects as follows:

 Connection
 Adapter
 Command
 Reader
 Dataset.

3.) State any 3 difference between ADO.NET and ADO?

 Recordset and Dataset


 Disconnected Architecture
 Lock Types

4.)what is Execute NOn Query?


Execute non Query is used to execute more than one command at the time (it is
used for
insert ,delete ,update) orthis method is invoked whenever DMLcommands has
been
excecuted

5.)What is @@rowcount and with small code snippet explain the usage?

@@rowcount gives the number of rows given as an result of previous query ran.
Create
procedure get_emp_count ( @emp_id int) As Select * from emp where emp_id
=@emp_id If @@rowcount = 0 Begin Select 'no rows with emp_id= ' Select
@emp_id
End

6.)What provider ADO.net use by default?


no default provider

7.)what is data access layer?

Data Access layer is actually a part of Architecture layer. It has 2 tier,3 tier or N
tier Layer. Generally we use 3 tier Layer 1) Presentation layer,Business Logic
layer and then Data Access Layer. Data Access layer is a medium to talk between
database and Business Logic layer. It helps to maintain flexibility,resuablity and
even secuity also. In security SQL Injection can be stopped with 3 iter
Archietcture.
8.)what is Sql Native Client?

www.twoengineers.co.in
SQL NATIVE CLIENT is a Provider used to Connect with the SQL Server
database

9.)What are advantages and disadvantages of Microsoft-provided data


provider
classes in ADO.NET?

SQLServer.NET data provider is high-speed and robust, but requires SQL Server
license
purchased from Microsoft. OLE-DB.NET is universal for accessing other
sources, like Oracle, DB2, Microsoft Access and Informix. OLE-DB.NET is a
.NET layer on top of the OLE layer, so it’s not as fastest and efficient as
SqlServer.NET.

www.twoengineers.co.in

You might also like