[freetds] freetds with QT 4.3 transaction support
James K. Lowden
jklowden at freetds.org
Thu Oct 18 19:44:51 EDT 2007
Ying He wrote:
> I am able to use QT 4.3 QTDS and freetds to connect to a MS SQL server
> and be able to do insert/update/delete/select. However, for some reason,
> transactions are not supported.
What do you mean by "not supported"? SQLEndTran() is supported and the
unit test (src/odbc/unittests/transaction.c) passes.
> I try to use QT 's QSqlDriver's hasFeature method to test and it shows
> the driver does not support transaction.
One thing you might do is get a TDSDUMP log to see what ODBC functions are
called by that method and maybe how it's deciding.
> anybody has any idea to work around this issue?
1. Fix our ODBC driver to report correctly (or to add a feature) if need
2. Fix Qt's function, if broken.
3. Ignore feature test and just use the function anyway, if possible.
4. Use T-SQL BEGIN TRAN, ROLLBACK, and COMMIT instead of ODBC
More information about the FreeTDS