Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. QMYSQL driver not loaded
Qt 6.11 is out! See what's new in the release blog

QMYSQL driver not loaded

Scheduled Pinned Locked Moved General and Desktop
4 Posts 3 Posters 2.7k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    Jarzka
    wrote on last edited by
    #1

    I have installed Qt SDK and developed a simple Library GUI program with it. However when I try to connect to a database I get the following error:
    QSqlDatabase: QMYSQL driver not loaded
    QSqlDatabase: available drivers: QSQLITE QODBC3 QODBC

    I can't figure out what this means or what should I do.

    1 Reply Last reply
    0
    • G Offline
      G Offline
      guziemic
      wrote on last edited by
      #2

      In my opinion, you do not have SqLite installed on system, or it is installed in such way that Qt does not see it. Some information can be found "here":http://doc.qt.digia.com/latest/sql-driver.html#qmysql

      1 Reply Last reply
      0
      • T Offline
        T Offline
        tobias.hunger
        wrote on last edited by
        #3

        It means that Qt does not include a driver to talk to mysql. There are lots of topics on the mysql driver here, search the forums, I am pretty sure that will turn up a description of how to build and set up that plugin.

        1 Reply Last reply
        0
        • J Offline
          J Offline
          Jarzka
          wrote on last edited by
          #4

          I found this site that helped me to build the plugin:
          http://ieatbinary.com/2011/07/11/how-to-enable-mysql-support-in-qt-sdk-for-windows/

          I put the dll files into the C:\QtSDK\Desktop\Qt<version>\mingw\plugins\sqldrivers but still Qt says it can't find the driver. :/

          1 Reply Last reply
          0

          • Login

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved