Professional Documents
Culture Documents
NET
SQL-SERVER
System.data.SqlClient
ORACLE
System.data.OracleClient
OleDB Providers
System.data.Oledb
ODBC
providers
System.data.ODBC
SQL Connection
Oracle Connection
OleDB Connection
ODBC Connection
SQL Command
Oracle Command
OleDB Command
ODBC Command
SQL Datareader
Oracle DataReader
ODBC DataProvider
SQL DataAdapter
Oracle DataAdapter
OleDB DataAdapter
ODBC DataAdapter
Provider Info
To connect to MS-Access 2000 above versions
Provider=microsoft.jet.oledb.4;datasource=databaseName.mdb
To connect to SQL-Server db
Provider=sqloledb.1;userid=sa;password=;database=database
name;datasource=servername
Note if SQL Connection is used then provider=providername is
not required.
To Connect to ORACLE
Provider =
oracleoledb.oracle;userid=scott;pwd=tiger;datasource =
servername
OR
Provider = msdaora.1;.
Note if oracle connection is used then provider= provider name
is not required.
To define DataReader
Dim objectName as xxxDataReader
To define DataAdapter
Dim objectName as xxxDataAdapter(Select
To define DataSet
Dim objectName as new DataSet()
To define DataView
Dim objectName as new
DataView(datasetName.DataMemberName)
primary key then the above step will define all the
commands of the dataAdapter else the commands
relevant for the update command and the delete
command will not be defined.
By writing code
Imports system.Data.Oledb
In the page_load
Dim objconn as new
oledbconnection(provider=oracledb.oracle;userid=sco
tt;password=tiger;datasource=servername)
Dim objDA as new oledbDataAdapter(Select * from
emp,objconn)
Dim ds as new dataSet
objdA.Fill(ds,emp)
Datagrid1.datasource = ds.Tables(0)
Datagrid1.databind()