ODBC, ADO or OLE DB

What library do you recommend for connecting a C ++ server with SQL .

I searched and found this , where is the discomfort that is best ODBC, ADO or OLE DB ?

In your opinion, if I have Windows XP SP 2, SQL Server 2008 and VIsual Studio 2008, what works simply and correctly ?.

Does anyone have a functional example to check ....

+4
source share
2 answers

For SQL Server, you probably want to use ADO.NET . There are many advantages to the SqlClient namespace that you simply don’t get with any other data access technology. It is also very easy to connect to SQL Server data sources, handle errors, etc.

The SqlClient namespace is specific to SQL Server, so if you have thoughts on creating a db-agnostic application, you need to look at other parameters, such as Data.Common namespace , which contains a nice factory model that allows you to write an access code, not provider dependent

0
source

They all work.

I would by default use my own client (system.data.sqlclient), since it is specially created for SQL-Server and probably has the most modern / optimized / full interface.

Here is some information from MSDN if this helps: http://msdn.microsoft.com/en-us/library/ms810810.aspx

0
source

All Articles