OracleConnection, is it ADO?

KenpoMatt

Active member
Joined
Jul 29, 2003
Messages
29
Location
West Chester, PA USA
I use Oracle as my primary database. I create my conection, command and reader objects like this:
Code:
Dim oConn as New OracleConnection
oConn.ConnectionString = "data source=myDataSource; user id =myID; password=myPassword"

Dim oCmd as New OracleCommand("select myField from myTable", oConn)

Dim oReader as OracleDataReader = oCmd.ExecuteReader
The data source name is not ODBC. It is an alias inside the TNSNames.ora file. So, this is a native Oracle connection, right?

I am assuming these are NOT ADO objects and they do not inherit from ADO. Can anyone confirm/deny my assumptions on this?

Just curious...

Thanks,
Matt
 
ADO (ADO.NET in this case) is not a kind of database, but rather a group of objects that allow you to connect to a database (any kind of database, as long as there is an ODBC driver available for it).

However, the OracleClient supported by the .NET framework (version 1.1 only) is indeed part of the ADO.NET library, just as much as the SqlClient or Oledb functionality is. Although Im not familiar at all with Oracle, I imagine that the ODBC driver is making a native connection to the Oracle data source. The OracleClient objects are simply wrappers to this connection.
 
I do understand that ADO is not a database. And, that it is a collection of classes used for data acces & management.

Im definitely not using ODBC. I believe Im using a native Oracle driver. Im curious if .Nets Oracle objects fall under the ADO.Net umbrella.

According to MSDN System.Data namespace, "consists mostly of the classes that constitute the ADO.NET architecture." OracleConnection et al reside in System.Data.OracleClient. It is the "mostly" part that makes me wonder whether OracleClient is part of ADO.Net.

I know from past experience that Oracle & ADO do not play well together. I wonder if MS & Oracle have agreed to collaborate on the ADO objects.
 
OracleClient is part of ADO.NET.

I wasnt thinking when I posted the thing about ODBC drivers - ADO.NET uses "Data Providers" (thats the SqlClient and whatnot) to interface with the databases. They are sort of like ODBC drivers, only written for ADO.NET. .NET 1.1 ships with an Oracle data provider, and thats what OracleClient uses.

Heres some light reading for you: http://www.fawcette.com/vsm/2003_01/magazine/features/beauchemin/default.asp
 
Back
Top