Solved MYSQL dll linking issue with QT in windows 10
-
Hey there,
I have problem in loading the qsqlmysqld.dll file,
I have used the same settings in other PC and in it, it is running perfectly and i can access the database.
But here i cannot get the access to Mysql Database.
When i run the Application using QT_DEBUG_PlUGINS i got this-Cannot load library C:\Qt\Qt5.12.3\5.12.3\mingw73_64\plugins\sqldrivers\qsqlmysqld.dll: The specified module could not be found. QLibraryPrivate::loadPlugin failed on "C:/Qt/Qt5.12.3/5.12.3/mingw73_64/plugins/sqldrivers/qsqlmysqld.dll" : "Cannot load library C:\\Qt\\Qt5.12.3\\5.12.3\\mingw73_64\\plugins\\sqldrivers\\qsqlmysqld.dll: The specified module could not be found."
can anyone suggest something, why it is not linking the above mentioned dll.
-
@mvsri said in MYSQL dll linking issue with QT in windows 10:
But here i cannot get the access to Mysql Database.
What is "here"? Another machine?
Most probably MySQL client library is missing. -
@jsulm "here" meant the current PC in which i'm trying to get access to mysql database.
And how can i check MySQL client Library whether it is missing or not?Thank you!
-
@mvsri Does C:\Qt\Qt5.12.3\5.12.3\mingw73_64\plugins\sqldrivers\qsqlmysqld.dll exist?
-
@jsulm yes, it exists
-
@mvsri I think you don't have MySQL connector installed on your PC ==> https://stackoverflow.com/questions/31821329/qmysql-driver-loading-error
You have to download it from MySQL web site and install it
-
@mvsri If it is working on the other PC then copy the MySQL client lib from there
-
@jsulm I have tried that, copied the lib files but it still doesn't work.
-
@KroMignon I have followed that steps earlier in other PC and it's working in it.
But the problem is when i try this in my PC it doesn't work and the configuration of both PC's are same and even i tried copying mysql client lib from other PC to my PC and still it doesn't work -
@mvsri said in MYSQL dll linking issue with QT in windows 10:
even i tried copying mysql client lib from other PC to my PC
Where / how did you copy it? And you should not distribute debug stuff (as qsqlmysqld.dll suggests you're doing)
-
@Christian-Ehrlicher
I have uninstalled everything and reinstalled QT and MYSQL following every step which i did on other PC.
But still i have the same problem. i even checked the PATH everything is correct and i don't know where am i going wrong. -
@mvsri Just to be sure every dependency is correctly set, can you try to check C:/Qt/Qt5.12.3/5.12.3/mingw73_64/plugins/sqldrivers/qsqlmysqld.dll with Dependency Walker ?