Presentation is loading. Please wait.

Presentation is loading. Please wait.

Objective In this session we will discuss about : What is ADO. NET ?

Similar presentations


Presentation on theme: "Objective In this session we will discuss about : What is ADO. NET ?"— Presentation transcript:

1

2 Objective In this session we will discuss about : What is ADO. NET ?
Assembly used in ADO.NET Namespace used in ADO.NET What is the full form of ADO? What are major difference between classic ADO and ADO.NET? ADO.NET Components NET Framework Data Provider

3 What is ADO. NET ? ADO. NET provides a bridge between the front end controls and the back end database.

4 Continue… ADO.NET is a set of classes that expose data access services for .NET Framework programmers. ADO.NET provides data access services in the Microsoft .NET platform. ADO.NET provides consistent access to data sources such as SQL Server and XML, and to data sources exposed through OLE DB and ODBC. Data-sharing consumer applications can use ADO.NET to connect to these data sources and retrieve, handle, and update the data that they contain. ADO.NET includes .NET Framework data providers for connecting to a database, executing commands, and retrieving results.

5 Assembly used in ADO.NET
The ADO.NET classes are found in System.Data.dll, and are integrated with the XML classes found in System.Xml.dll. ADO.NET is a set of computer software components that programmers can use to access data and data services based on disconnected DataSets and XML.

6 Namespace used in ADO.NET
Disconnected Connected

7 What is the full form of ADO?
The full form of ADO is ActiveX Data Object.

8 Features of ADO.NET Contains a number of classes that provide you with various methods and attributes to manage the communication between your application and data source. Enables you to access different data sources, such as Microsoft SQL Server, and XML, as per your requirements. Provides a rich set of features, such as connection and commands that can be used to develop robust and highly efficient data services in .NET applications. Provides various data providers that are specific to databases produced by various vendors. For example, ADO.NET has a separate provider to access data from Oracle databases; whereas, another provider is used to access data from SQL databases.

9 What are major difference between classic ADO and ADO.NET?
In ADO we have recordset and in ADO.NET we have dataset. In recordset we can only have one table. If we want to accommodate more than one tables. We need to do inner join and fill the recordset. Dataset can have multiple tables. All data persist in XML as compared to classic ADO where data persisted in Binary format also.

10 ADO.NET Components Data Set Data providers
The two main components of ADO.NET 3.0 for accessing and manipulating data are the .NET Framework data providers and the DataSet. Data Set Data providers

11 .NET Framework Data Provider

12 Data provider An ADO.NET data provider is a software component that interacts with a data source. It is required for : Connecting to a database. Retrieving data. Storing the data in a dataset. Reading the retrieved data. Updating the database.

13 List of Data provider

14 Continue… .NET Framework Data Provider for SQL Server (SqlClient)
.NET Framework Data Provider for OLE DB .NET Framework Data Provider for ODBC .NET Framework Data Provider for Oracle

15 Core Objects of .NET Framework Data Providers

16 Creating and Managing Connections
To create and manage connections, you need to: Create a connection object. Create a command object. Open the connection object. Execute the SQL statement in the command object. Close the connection object.

17 SqlConnection Class

18 Ex

19 SqlCommand

20 Continue…

21 Ex

22 Adding Parameters to Commands

23 Command Using Stored Procedures

24 SqlCommand run a stored procedure that takes a parameter

25 Data Reader

26 Ex

27 Data Adapter

28 Continue…

29 Continue… The DataAdapter object serves as a conduit between the data source and the Dataset. The DataAdapter knows about the DataSet and it knows how to populate it.

30 Continue…

31 Ex

32

33 Continue…

34 Summary!!


Download ppt "Objective In this session we will discuss about : What is ADO. NET ?"

Similar presentations


Ads by Google