Skip to Content.
Sympa Menu

freetds - Re: [freetds] freetds with QT 4.3 transaction support

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "Ying He" <yhe AT devonit.com>
  • To: "FreeTDS Development Group" <freetds AT lists.ibiblio.org>
  • Subject: Re: [freetds] freetds with QT 4.3 transaction support
  • Date: Fri, 19 Oct 2007 13:43:18 -0400

Hi,
I was using freetds's tds driver not odbc driver. Now I am trying again
with freetds's odbc driver. The connection is opened successfully but I
get a bunch of the the following:

qGetStringData: Error while fetching data (-1)
qGetStringData: Error while fetching data (-1)

I don't see anything showing error in TDSDUMP
Any idea what is going wrong?

best,
Ying

-----Original Message-----
From: freetds-bounces AT lists.ibiblio.org
[mailto:freetds-bounces AT lists.ibiblio.org] On Behalf Of James K. Lowden
Sent: Thursday, October 18, 2007 7:45 PM
To: FreeTDS Development Group
Subject: Re: [freetds] freetds with QT 4.3 transaction support

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
be.
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
abstractions.

HTH.

--jkl
_______________________________________________
FreeTDS mailing list
FreeTDS AT lists.ibiblio.org
http://lists.ibiblio.org/mailman/listinfo/freetds






Archive powered by MHonArc 2.6.24.

Top of Page