Skip to Content.
Sympa Menu

freetds - Re: [freetds] 0.63 bug - error messages garbled

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: Evan Rempel <erempel AT uvic.ca>
  • To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
  • Subject: Re: [freetds] 0.63 bug - error messages garbled
  • Date: Tue, 16 Aug 2005 13:35:57 -0700 (Pacific Standard Time)


Thanks.

This seems to fix the problem.
I now get appropriate error messages returned from the sql server.

Evan Rempel.

On Sun, 14 Aug 2005, Frediano Ziglio wrote:

Date: Sun, 14 Aug 2005 11:14:10 +0200
From: Frediano Ziglio <freddyz77 AT tin.it>
Reply-To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
Subject: Re: [freetds] 0.63 bug - error messages garbled

Il giorno gio, 11/08/2005 alle 11.26 -0700, Evan Rempel ha scritto:
Thanks for the suggestions. The logs are a little difficult fo me to read.
It appears that ODBC does not get the error message back from the TDS
driver

[ODBC][20729][SQLPrepare.c][364]
Exit:[SQL_ERROR]
[ODBC][20729][SQLError.c][342]
Entry:
Statement = 0x896cb28
SQLState = 0xbfffa870
Native = 0xbfffa848
Message Text = 0xbfffa880
Buffer Length = 511
Text Len Ptr = 0xbfffa84e
[ODBC][20729][SQLError.c][379]
Exit:[SQL_NO_DATA]

I have included both logs for both unixODBC and for freetds when
using freetds 0.62.4 which is successful, and freetds 0.63 which is
unsuccessful.

Evan.


There seems a couple of problems here
- FreeTDS do not catch error preparing statement
- your program do not check SQLError result
- FreeTDS try to execute invalid prepared statement

I fix first error. Attached post 0.63 patch

freddy77



--
Evan Rempel erempel AT uvic.ca
Senior Programmer Analyst 250.721.7691
Computing Services
University of Victoria




Archive powered by MHonArc 2.6.24.

Top of Page