I tryed this code.

But,,,
Now There is an error on Console.
----Eror message----------------------------------------------------------
QSqlDatabase: QMYSQL driver not loaded
QSqlDatabase: available drivers: QSQLITE QODBC3 QODBC

Correct me if I am wrong… you wanted to use MySQL in the QSqlDatabase?
Yeah, I want to use MySQL in th QSqlDatabase.
I knew the module from a book about Qt from O'REILLY.
but the book don't written about how to configure the environment.

Then the thing you added in the .pro file has nothing to do with it…
ohh, really? so how to recognition the Qtcreator to the include path of MySQL?

What you need is the QMYSQL plugin/driver for Qt. You actually need to build/rebuild Qt yourself and >passing “-qt-sql-mysql” to configure