ODBC or OLE DB

  • Thread starter Thread starter Chris
  • Start date Start date
C

Chris

Hi,

What should I choose ODBC or OLE DB?
I need to connect to Oracle, SQLServer, Ingres and maybe MySQL.
I am not using stored procedures.

I cannot find any microsoft recomendations on there MSDN site.

Can anyone point me to some documents that have the benifits of one over the
other. i.e Performance Issues....

Thanks

Chris
 
As long as you can find providers for each database, OLEDB is faster than
ODBC. ODBC has more options, but I believe you can find providers for all of
the databases you have listed (have not tried Ingres personally; there is an
open source driver for MySql, however).

--
Gregory A. Beamer
MVP; MCP: +I, SE, SD, DBA

*************************************************
Think outside of the box!
*************************************************
 
Hi,

Thanks for the reply, but do you know if there is a document where they
compare response times etc?

Regards

Chris
 
Hello Chris,

Generally OLE DB is preferrable because it can retrieve data a bit more efficiently
than ODBC...*but* it all depends on the quality of the driver/provider. It
is not difficult to write a badly performing OLE DB provider that is slower
than its ODBC counterpart. In general you will also find that the Managed
Providers (ADO.NET) for SQL Server and Oracle will out perform their OLE
DB/ODBC because of marshaling issues.

I know its a lot of opinion without a lot of data, but there are so many
things that can impact performance, usually the provider of the data is just
one of a number of possible cause of performance issues.

Thanks,
Shawn Wildermuth
Speaker, Author and C# MVP
http://adoguy.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top