Few questions about Access Databases:
1) How do I create one on demand, with my code?
2) General Usage: Executing SQL Statements + Handling Results
i.e. Updating, Deleting, Inserting, Selecting etc
I think that's it :D
Please help!
Printable View
Few questions about Access Databases:
1) How do I create one on demand, with my code?
2) General Usage: Executing SQL Statements + Handling Results
i.e. Updating, Deleting, Inserting, Selecting etc
I think that's it :D
Please help!
Or a similar database format with same functions + decent size compression ;p?
MS gives you at least 4 ways to access a Access database from C/C++.
1) The ODBC SQL API. No idea how it works or where it can be found. The most C-like API.
2) The OLE Database Objects. Very complicated. The OLE DB Templates in VS.Net are supposed to make it easier, but I don't understand them either.
3) DAO, the Database Access Objects. A set of dual interface COM objects to access any ODBC database and Access in particular. Written for VB and a pain to use in C++, even more so in C.
4) ADO, the Active Data Objects. Supersedes DAO, with the same shortcomings.
Then there are the MFC database classes, based on ODBC SQL API or DAO. They are fairly easy to work with, but require MFC.
Alternatives:
Most database vendors offer their own specific APIs. MySQL for example provides both a C and an excellent C++ API. Unfortunatly the Windows version of the C++ API is outdated. MySQL databases are not as easy to distribute as Access files.