QMYSQL driver not loaded - again?...
-
Hi
If the database server is on other computer then
db.setHostName("localhost");
should be ip or name of that server as far as I know.
localhost cannot be "other" pc.
Also note the port 3306.
Might be blocked by windows firewall. -
okay, but this is not the problem, i think.
I read of copying files like libmysql.dll and so on,
but i do not understand what i exactly have to do :/@mr__710
well does it still work to load database from own pc?did u read this ?
https://forum.qt.io/topic/25638/qsqldatabase-qmysql-driver-not-loaded-why -
with data.db on my pc it worked.
db = QSqlDatabase::addDatabase("QSQLITE"); db.setDatabaseName("C:/sqlite/data.db");
this was no problem.
-
I installed MYSQL to c://MySql.
What files do i have to copy and in which folder of QTdir?it depends on your qt version but this for 5
http://seppemagiels.com/blog/create-mysql-driver-qt5-windows
Step 5 -
Perfect, with mingw it works now.
Unfortunately i have to compile it on android with armeabi-v7.There i get errors again, what do i have to change?
-
ok, thank you so far.
If someone wants to help: http://forum.qt.io/topic/61141/mysql-database-connection-mingw-yes-android-no