Reputation: 935
If I have to download Connector would I also need to download it on any computer I want to use the C++ application on? I haven't started any code for the database part yet but I'm writing an application that reads data and I want to store that in a mysql database using C++.
Upvotes: 0
Views: 243
Reputation: 5118
Is Using MySql Connector/C++ necessary in order to access/change mysql database?
You don't have to connect to the official MySQL connector. You can use ODBC or other custom connectors.
If I have to download Connector would I also need to download it on any computer I want to use the C++ application on?
It depends whether you link to the MySQL connector library statically or dynamically.
libmysqlcppconn-static.a
(or .lib
on windows), and will allow you to run your program on environments where the mysql connector is not installed.libmysqlcppconn.so
(or .dll
on windows, .dylib
on macOS), and will require your program to run on environments where the mysql connector has been installed.This question discusses the tradeoffs of static vs. dynamic linking in more details.
This questions discusses the licensing implications of using MysQL connector.
Upvotes: 1