Professional Documents
Culture Documents
IN .NET
ADO
COM BASED MODEL
ADO.NET
NAME SPACE MODEL
ADO.NET
CONNECTION ORIENTED MODEL
DISCONNECTED ORIENTED MODEL
CONNECTION ORIENTED
MODEL
Whenever an application uses the
connection oriented model to interact with
the db then the connectivity between the
application and the database has to be
maintained always.
Connection Oriented
Application
db
DATA PROVIDERS
Data Reader
Command
Connection
DISCONNECTED MODEL
Application
DataSet
Data View
This is available in
client system
Data Adapter
Connection
Data Providers
Database
Disconnected Model
Connection it is used to establish the physical
connection between the application and the database
DataAdapter it is a collection of commands which acts
like a bridge between the datastore and the dataset.
Commands in DataAdapter
DataAdapter
Select Command
Table Mappings
Insert Command
Update Command
Delete Command
Update(Dataset Name[,DataMember])
Fill Method
It is used to fill the data retrieved by the select
command of DataAdapter to the dataset.
Data Adapter
Select Command
Select * from emp
Fill(ds,emp)
DS
db
Update Method
It is used to update the dataAdapter with the
data present in the dataMember of the dataSet.
In other words used to the update the
database.
Data Adapter
Update(ds,emp)
DS
db
DataSet
It is an in memory representation of the data in the
format of XML at the client system.
Points to remember about DataSet:
It contains any no of datatables which may belong to the
Data Set
DataSet is of 2 types
Typed DataSet when ever the dataset is
DataView
It is logical representation of the data
present in the datamember of dataSet.
Usage It is used to sort the data,filter
the data or if the data has to be projected in
the pagewise then the dataView should be
used.
Command
It is used to provide the source for
executing the statement I.e it used to
specify the command to be executed.
Data Reader
It is a forward and read only record set
which maintains the data retrieved by the
select statement.
ADO.NET
DISCONNECTED MODEL
CONNECTION
CONNECTION
DATA ADAPTER
COMMAND
DATA SET
DATA READER
DATA VIEW
UI
UI
Used if the data has to be filtered,
sorted or if the data has to be projected
in page-wise