Results 1 to 4 of 4

Thread: Cannot connect to mysql database

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Wiki edits
    17

    Default Re: Cannot connect to mysql database

    QSqlDatabase::lastError() and the console output from the program will probably tell you exactly what the problem is.

    Fearu is correct about the absence of a Qt MySQL plugin in the shipped Qt SDK on Windows. Most Linux builds will have it, but I don't know if the shipped SDK bundle does.

  2. The following 2 users say thank you to ChrisW67 for this useful post:


  3. #2
    Join Date
    Oct 2011
    Posts
    13
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Thanks
    3
    Thanked 4 Times in 2 Posts

    Default Re: Cannot connect to mysql database

    You're right.
    Here is the software output when I try to connect to database.
    Démarrage de C:\Users\HP\Desktop\lastClient\callTracker-build-desktop-Qt_4_7_4_for_Desktop_-_MinGW_4_4__Qt_SDK__Debug\debug\callTracker.exe... QSqlDatabase: QMYSQL driver not loaded
    QSqlDatabase: available drivers: QSQLITE
    Thanks

  4. The following 2 users say thank you to phapha for this useful post:


Similar Threads

  1. Connect to database
    By seink in forum Newbie
    Replies: 12
    Last Post: 26th April 2011, 18:43
  2. How to connect Qt with MYSQL??
    By Gokulnathvc in forum Newbie
    Replies: 10
    Last Post: 24th March 2011, 00:52
  3. Mysql unknown database, QMYSQL unable to connect
    By lixo1 in forum Qt Programming
    Replies: 3
    Last Post: 14th July 2010, 21:39
  4. Qt connect different MySQL
    By weixj2003ld in forum Qt Programming
    Replies: 0
    Last Post: 5th August 2009, 08:35
  5. How to connect MySQL with QT
    By diego in forum Qt Programming
    Replies: 0
    Last Post: 27th May 2009, 05:34

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.