darkadept
1st April 2008, 15:44
I'm trying to develop an app for Windows using the QODBC driver to connect to Microsoft SQL Server. I'm using mingw to compile. I am doing a lot of my actual development under Linux with Mysql but then I want to port my application to run on windows.
I'm using basic Qt classes to connect to the database, QSqlTableModel, QSqlQuery, QTableView, and QDataWidgetMapper. I'm doing nothing fancy and it works perfectly with Mysql.
But it seems like only a small subset of classes that actually work with ODBC. I initially tried to use QSqlQuery using the bind values method and that fails.
Using table views and table models seem to work but now that I'm trying to use QDataWidgetMapper I get a ton of errors about being "unable to bind variable".
[edit] The actual error i'm getting (when QDataWidgetMapper tries to save the data to the database is:
QODBCResult::exec: unable to bind variable: [Microsoft][ODBC SQL Server Driver]Optional feature not implemented
Is anyone actually using Microsoft Sql Server via ODBC on Windows with any success?
I'm using basic Qt classes to connect to the database, QSqlTableModel, QSqlQuery, QTableView, and QDataWidgetMapper. I'm doing nothing fancy and it works perfectly with Mysql.
But it seems like only a small subset of classes that actually work with ODBC. I initially tried to use QSqlQuery using the bind values method and that fails.
Using table views and table models seem to work but now that I'm trying to use QDataWidgetMapper I get a ton of errors about being "unable to bind variable".
[edit] The actual error i'm getting (when QDataWidgetMapper tries to save the data to the database is:
QODBCResult::exec: unable to bind variable: [Microsoft][ODBC SQL Server Driver]Optional feature not implemented
Is anyone actually using Microsoft Sql Server via ODBC on Windows with any success?