Wednesday, October 15th 2008, 9:45pm UTC+1

You are not logged in.

  • Login
  • Register

Dear visitor, welcome to QtForum.org. If this is your first visit here, please read the Help. It explains how this page works. You must be registered before you can use all the page's features. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

1

Wednesday, December 12th 2007, 12:43pm

how to create a connection using QODBC and QT 4.2.3

hi all,

how to make a connection of QODBC and Qt 4.2.3


Regards,
yasodha
  • Go to the top of the page

2

Monday, December 17th 2007, 11:18am

hi if you use a mdb file you can connect to it dirctly
if you want a sample replay
  • Go to the top of the page

3

Tuesday, December 18th 2007, 2:02pm

hi
i just do it now
i connect mysql with odbc by mysql-odbc driver
then i connect odbc with qt
and its work
if that is your asking for
replay me
  • Go to the top of the page

4

Wednesday, March 5th 2008, 11:01pm

hey,
I notice you said to use odbc to connect to mysql using the odbc connector. Can you tell me the exact steps to do it? What I did was

QSqlDatabase db = QSqlDatabase::addDatabase("QODBC", "PLC");
if (!db.open()) {
QMessageBox::critical(0, QObject::tr("Database Error"),
db.lastError().text());
return false;
}

Where PLC is my DSN. However, I am getting this error -
[Microsoft][ODBC Driver Manager] Data Source name not found and no default driver specified QODBC3: Unable to Connect.
  • Go to the top of the page

Rate this thread