Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

Linux Mint 20 Qt 5.15.0 MySQL driver not loaded



  • I have been through just about everything there is on this forum and others and I am still stuck.

    I have the MySQL client libraries loaded.

    I have several questions still unanswered.

    1. Why is this driver not included in the online installer scripts? Postgresql and SQLite are included but not MySQL (the more often seen product).
    2. Almost all the questions on forums are about Windows...which should not be a problem if I had windows - anywhere.
    3. Does MySQL server have to be installed on the client machine? It seems when I installed the client libraries, the install scripts tried to start the server. The host database is not local. The only access is on the WAN.
    4. So what do I do now? The procedures I have seen so far, make use of any other system (even another Linux system) very complicated for users.

    I don't have the libqsqlmysql module so ldd is out of the question. The source for Qt 5.15.0 does not seem to have a source for this driver, so the configure script talked about in one post would not work either.

    The host computer must connect to the application and the database host is MySQL. I am stopped at this point so any help would be appreciated.

    Environment is:
    Linux Mint 20 Cinnamon Kernel 4.40-40-generic
    Qt 5.15.0
    Host server MySQL 8 Client MySQL 8


  • Lifetime Qt Champion

    Hi,

    1. this question has already been answered on this forum several times. Oracle changed their licensing so the driver can't be provided pre-built anymore.

    2. the instructions doesn't change much in this case as you can see in the driver's documentation.

    3. no, the client machine only requires the client library.

    4. Follow the instructions from the documentation.

    If the sources do not contain the driver code, then it means that your copy is incomplete. You should download them again.



  • OK, reloaded Qt and was able to compile the driver. It now shows up in the drivers list.
    The problem with the driver seems to be resolved for the moment. Now to get the server side port open to the WAN.


  • Lifetime Qt Champion

    Don't forget to take into account that at this time and age, it's not recommended to have your database directly exposed over internet.


Log in to reply