X-Original-To: pgsql-odbc-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 29C90D70AA for ; Thu, 1 Sep 2005 13:32:55 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 59679-08 for ; Thu, 1 Sep 2005 16:32:45 +0000 (GMT) Received: from svctag-ckgvz71.mailserver.wazagua.com (unknown [209.34.245.244]) by svr1.postgresql.org (Postfix) with ESMTP id 35F7CD77A7 for ; Thu, 1 Sep 2005 13:32:44 -0300 (ADT) Received: from jfradkin ([66.15.127.235]) by svctag-ckgvz71.mailserver.wazagua.com with Microsoft SMTPSVC(6.0.3790.1830); Thu, 1 Sep 2005 12:31:39 -0400 From: "Joel Fradkin" To: "'Dave Page'" Cc: Subject: Re: figuring out why I am having this issue Date: Thu, 1 Sep 2005 12:34:00 -0400 Message-ID: <000001c5af12$f5baf670$797ba8c0@jfradkin> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable In-Reply-To: X-OriginalArrivalTime: 01 Sep 2005 16:31:39.0343 (UTC) FILETIME=[A0E2FDF0:01C5AF12] X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=2.905 required=5 tests=[AWL=-0.171, MSGID_DOLLARS=3.076] X-Spam-Level: ** X-Archive-Number: 200509/15 X-Sequence-Number: 5913 So I am not even using libpq (figures). Seemed to be working ok until this issue with the data. I do not have control over what they store, I can modify single quotes = to '' and such. I am using .net project where would I define USE_LIBPQ? Joel Fradkin =20 =20 -----Original Message----- From: Dave Page [mailto:dpage@vale-housing.co.uk]=20 Sent: Thursday, September 01, 2005 12:14 PM To: Joel Fradkin Cc: pgsql-odbc@postgresql.org Subject: RE: [ODBC] figuring out why I am having this issue =20 > -----Original Message----- > From: Joel Fradkin [mailto:jfradkin@wazagua.com]=20 > Sent: 01 September 2005 16:16 > To: Dave Page > Cc: pgsql-odbc@postgresql.org > Subject: RE: [ODBC] figuring out why I am having this issue >=20 > That is the error description=20 > If con.Errors.Count >=3D 1 Then > set Error =3D con.Errors.Item(0) > 'take the error code from SQL Server=20 > ErrCode =3D Error.NativeError > response.Write(cstr(Error.Description)) > Response.End > End If >=20 > Could be there is better method, but this what I have been using. Dunno if there's a better method - I would be inclined to loop round con.Errors.Count though - maybe something like: For X =3D 1 To con.Errors.Count set Error =3D con.Errors.Item(X - 1) 'take the error code from SQL Server=20 ErrCode =3D Error.NativeError response.Write(cstr(Error.Description)) End If Response.End > I have tested putting a 300 meg text field in the data base=20 > nad it worked so > not clear why it works on most data and this one does not. > I did email you the log file (not sure it is any help). Yeah, I can't see anything obviously wrong in it. A few things to consider though: - ASP seems to be retrieving data as SQL_C_CHAR, which means it's getting raw data, not UCS2 converted from UTF8. - ASP is retrieving data in 32KB chunks, so it would probably be worth making sure max_long_varchar is at least that. - Some data (quotes and such) doesn't look so good. Could it have been pasted from MS Word or similar? - Are you compiling the driver yourself? If so how? It seems to be using the old comms layer, not libpq (which I'm no longer working on). The giveaway is lines like the following which are for debugging the network protocol: connecting to the server socket... connection to the server socket succeeded. sizeof startup packet =3D 292 sent the authentication block. sent the authentication block successfully. gonna do authentication read 15, global_socket_buffersize=3D8192 auth got 'R' areq =3D 0 auth got 'K' auth got 'Z' All this is now encapsulated in libpq, which doesn't log what it's doing. To fix this, compile on the command line: nmake /f win32.mak This should ensure you get the default libpq build. If you're doing this in an IDE, make sure USE_LIBPQ is defined! Regards, Dave.