I am using Visual C++ 2008 to create the desktop application with C++.but i don't know how to connecting and execute some database with C++.i am newbie in C++,before it i was a php programmer and can handle some database structure with MySQL.do you know how to using C++ with Microsoft Access or Microsoft SQL and coding it with C++?
any tutorial about using database with C++?
How To Connecting and Use Database With C++?
Page 1 of 1
tutorial about database with visual C++ 2008
1 Replies - 6989 Views - Last Post: 06 October 2010 - 02:02 AM
Replies To: How To Connecting and Use Database With C++?
Re: How To Connecting and Use Database With C++?
Posted 06 October 2010 - 02:02 AM
There are at least 2 ways to connect to most databases on Windows
- Connection through a native propitiatory library. Most (many) database engines ship with a library of functyions that a C/C++ program can link to in order to use the database. I don't have much experience of this, but you would expect such a program to have a speed advantage because it uses native code but it would also be locked into 1 database engine.
- ODBC - (Open DataBase Conectivity) this allows the user to set up a data source, the data source is not restricted to a particular database engine. The program then links to and makes calls to the ODBC API (OBDC reference) the ODBC lay makes the connection and provides a standardised SQL syntax for the user that it then interprets into the specific SQL dialect of the data source. The application is not locked to a single database engine but does have an extra layer of code so is likely to have a speed penalty.
Page 1 of 1