Qt World Summit: Register Today!

QSqlDatabase: QPSQL driver not loaded with PostgreSQL 12.0?

  • Hi,
    When I download PostgreSQL 9.6 ODBC driver and put them in the D:\ProgramFiles\Qt\5.13.1\msvc2017_64\bin location than My program works OK and can connect the PostgreSQL 9.6 database.
    But when I download 12.0 ODBC files and put them in same above location than I got error QSqlDatabase: QPSQL driver not loaded!?
    What is the problem with PostgreSQL 12.
    Unfortunatelly I work on Windows. And if I can not solve this than I will install PostgreSQL 9.6. Because with 9.6 I can connect the database without problem.

  • Lifetime Qt Champion


    Did you check the error text you get from QSqlDatabase ?
    One other thing you can do is start your application with the QT_DEBUG_PLUGINS environment variable set to 1 to get more information related to the plugins.

  • Dear @SGaist ,
    Thanks. I did not ─▒nderstand but there are different set of psqlodbc-12.0-1 zip file in the website. I installed psqlodbc-12.0 from msi file on windows and path it to Qt and now everything is OK... Before I tryed to use zip pack but there are different files in both of this folders.

    Thanks a lot.


  • This post is deleted!

Log in to reply