Results 1 to 6 of 6

Thread: Qt and Mysql connector C++

  1. #1
    Join Date
    Oct 2010
    Posts
    5
    Qt products
    Qt/Embedded
    Platforms
    Windows

    Default Qt and Mysql connector C++

    Hi!
    I'm trying to use Mysql connector C++ to connect to Mysql server. For that I use these include files:
    #include "cppconn/driver.h"
    #include "mysql_connection.h"
    but they cant be read by the compiler.
    Help please!
    Geat thanks!

  2. #2
    Join Date
    Jan 2006
    Location
    Germany
    Posts
    4,380
    Thanks
    19
    Thanked 1,005 Times in 913 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows Symbian S60
    Wiki edits
    5

    Default Re: Qt and Mysql connector C++

    Let me ask an other question: Why do you don't use QSqlDatabase to connect to your MySQL server?

  3. #3
    Join Date
    Oct 2010
    Posts
    5
    Qt products
    Qt/Embedded
    Platforms
    Windows

    Default Re: Qt and Mysql connector C++

    Can I use it to verify if I am connected to Mysql server or not?

  4. #4
    Join Date
    Jan 2006
    Location
    Belgium
    Posts
    1,938
    Thanked 268 Times in 268 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Wiki edits
    20

    Default Re: Qt and Mysql connector C++


  5. #5
    Join Date
    Oct 2010
    Posts
    5
    Qt products
    Qt/Embedded
    Platforms
    Windows

    Default Re: Qt and Mysql connector C++

    yes but I would like to verify if I am connected to Mysql server not to a database

  6. #6
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Qt and Mysql connector C++

    As far as I know you can't connect to a MySQL server without specifying any database because the access rights are often different for different databases.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


Similar Threads

  1. I need MySQL driver for Qt 4.6, WindowsXP(32), MySQL 5.1
    By User_3 in forum Installation and Deployment
    Replies: 7
    Last Post: 15th October 2010, 15:19
  2. MySQL on Qt4
    By ^NyAw^ in forum Qt Programming
    Replies: 4
    Last Post: 10th April 2008, 16:12
  3. AVC, automatic widget/variable connector
    By pollastri in forum Qt-based Software
    Replies: 0
    Last Post: 12th November 2007, 17:33
  4. mysql 5.0.41 and qt 4
    By locus in forum Installation and Deployment
    Replies: 2
    Last Post: 20th June 2007, 07:08
  5. MYSQL 5 Table qt model as small Mysql admin
    By patrik08 in forum Qt-based Software
    Replies: 0
    Last Post: 1st May 2007, 09:43

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
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.