Skip to Content.
Sympa Menu

freetds - [freetds] fisql hangs on a query but tsql doesn't

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: Robert Marsa <Robert.Marsa AT clickforensics.com>
  • To: "freetds AT lists.ibiblio.org" <freetds AT lists.ibiblio.org>
  • Subject: [freetds] fisql hangs on a query but tsql doesn't
  • Date: Wed, 17 Mar 2010 16:54:54 -0500


Hi all.

I'm having a strange problem with freetds and MS SQL Server. Certain queries
execute fine using tsql, but hang when using fisql, bsqldb, or my app which
uses the db-lib API.

The behavior I see is that dbsqlexec() doesn't return. Examining the source
indicates that dbsqlok() does more-or-less the same thing as tsql does.

The tdsdump shows the following for tsql:

write.c:164:tds_put_string wrote 1604 bytes
util.c:162:Changed query state from QUERYING to PENDING
net.c:779:Sending packet
0000 01 01 06 4c 00 00 01 00-73 00 65 00 6c 00 65 00 |...L.... s.e.l.e.|
.
.
.
0640 65 00 54 00 69 00 6d 00-65 00 0a 00 |e.T.i.m. e...|

token.c:495:tds_process_tokens(0x1c97ab0, 0x7fff98487998, (nil), 0x6914)
util.c:162:Changed query state from PENDING to READING
net.c:592:Received header
0000 04 00 10 00 00 e0 01 00- |........|

net.c:671:Received packet
0000 81 0b 00 00 00 08 00 3d-0d 43 00 6c 00 69 00 63 |.......= .C.l.i.c|
...

For fisql, I get:

write.c:164:tds_put_string wrote 1604 bytes
util.c:162:Changed query state from QUERYING to PENDING
net.c:779:Sending packet
0000 01 01 06 4c 00 00 01 00-73 00 65 00 6c 00 65 00 |...L.... s.e.l.e.|
.
.
.
0640 65 00 54 00 69 00 6d 00-65 00 0a 00 |e.T.i.m. e...|

dblib.c:4532:dbsqlok(0x1a7f260)
dbutil.c:213:tds_int_handler 0x1a7f260 [0x404360,
0x404370]dbutil.c:213:tds_int_handler 0x1a7f260 [0x404360,
0x404370]dbutil.c:213:tds_int_handler 0x1a7f260 [0x404360, 0x40437
0]dbutil.c:213:tds_int_handler 0x1a7f260 [0x404360,
0x404370]dbutil.c:213:tds_int_handler 0x1a7f260 [0x404360,
0x404370]dbutil.c:213:tds_int_handler 0x1a7f260 [0x404360, 0x404
370]dbutil.c:213:tds_int_handler 0x1a7f260 [0x404360,
0x404370]dbutil.c:213:tds_int_handler 0x1a7f260 [0x404360,
0x404370]dbutil.c:213:tds_int_handler 0x1a7f260 [0x404360, 0x4
04370]dbutil.c:213:tds_int_handler 0x1a7f260 [0x404360,
0x404370]dbutil.c:213:tds_int_handler 0x1a7f260 [0x404360,
0x404370]dbutil.c:213:tds_int_handler 0x1a7f260 [0x404360, 0
x404370]dbutil.c:213:tds_int_handler 0x1a7f260 [0x404360,
0x404370]dbutil.c:213:tds_int_handler 0x1a7f260 [0x404360,
0x404370]dbutil.c:213:tds_int_handler 0x1a7f260 [0x404360,
0x404370]dbutil.c:213:tds_int_handler 0x1a7f260 [0x404360,
0x404370]dbutil.c:213:tds_int_handler 0x1a7f260 [0x404360,
0x404370]dbutil.c:213:tds_int_handler 0x1a7f260 [0x40436
0, 0x404370]dbutil.c:213:tds_int_handler 0x1a7f260 [0x404360,
0x404370]dbutil.c:213:tds_int_handler 0x1a7f260 [0x404360,
0x404370]dbutil.c:213:tds_int_handler 0x1a7f260 [0x404

This continues until I kill the process.

I've tried using freetds from Ubuntu and Mac OS X with the same result. The
machines are on the same local network as the SQL Server box and there are no
firewalls or anything else in between.

Any ideas what might be happening?

Thanks,

Robert







Archive powered by MHonArc 2.6.24.

Top of Page