X-Original-To: pgsql-odbc-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id D46CB9DC9AE for ; Fri, 10 Feb 2006 06:55:43 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 51451-08 for ; Fri, 10 Feb 2006 06:55:45 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey- Received: from mail.codata.be (217.64.244.119.mactelecom.net [217.64.244.119]) by postgresql.org (Postfix) with SMTP id 36ECA9DC888 for ; Fri, 10 Feb 2006 06:55:40 -0400 (AST) Received: FROM [217.112.178.162] BY mail.codata.be with hMailServer ; Fri, 10 Feb 2006 11:55:42 +0100 Message-ID: <43EC712E.1060707@freesurf.fr> Date: Fri, 10 Feb 2006 11:55:42 +0100 From: Arnaud Lesauvage User-Agent: Thunderbird 1.5 (Windows/20051201) MIME-Version: 1.0 To: Magnus Hagander CC: pgsql-odbc@postgresql.org, Dave Page , Ludek Finstrle Subject: Re: Slow query through ODBC References: <6BCB9D8A16AC4241919521715F4D8BCE6C7FD9@algol.sollentuna.se> In-Reply-To: <6BCB9D8A16AC4241919521715F4D8BCE6C7FD9@algol.sollentuna.se> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.472 required=5 tests=[AWL=-0.008, DNS_FROM_RFC_ABUSE=0.479, UNPARSEABLE_RELAY=0.001] X-Spam-Score: 0.472 X-Spam-Level: X-Archive-Number: 200602/49 X-Sequence-Number: 7178 Magnus Hagander a écrit : > Since it works with different speeds in different clients, it *probably* > isn't on the server side. I'm far from sure on that though, there may be > other paramters that are implicitly changed when ODBC is used. Yes, that was my first impression also. But the fact that the server waits for an ACK from the client before it goes on sending packet is quite strange, isn't it ? > It's interesting to note that your problem is with a single large field. > If you query for approximatly the same amount of data *but in several > small fields*, do you get the same behaviour? Or does it happen only > with large fields? I have splitted the data into 4 fields. The largest field was ~23.000 characters long, so I made 4 fields containing. The first one contains the first 6000, the second one from 6001 to 12000, etc... The query took about half the time to run ! > We enable TCP_NODELAY on both server and client, when available. And it > is available - I've double-checked and that code is indeed compiled into > both libpq and the server on 8.1 at least. I run 8.1.2, so I assume that it is enabled on my workstation and on the server. > But I don't see how this can make a difference between pgadmin and odbc > and psql, since they all use the same code! Yes, I really don't understand either ! But even though all use libpq.dll, they might not handle the data the same way. Mayboe ODBC needs to check for data type, field length, etc... and the other frontends do not need this kind of information ? Regards -- Arnaud