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 D01CFDB936 for ; Wed, 16 Nov 2005 20:47:21 -0400 (AST) 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 79210-03-3 for ; Thu, 17 Nov 2005 00:47:21 +0000 (GMT) X-Greylist: delayed 03:05:39.294847 by SQLgrey- Received: from svr2.postgresql.org (svr2.postgresql.org [65.19.161.25]) by svr1.postgresql.org (Postfix) with ESMTP id C59BDDAA89 for ; Wed, 16 Nov 2005 20:47:15 -0400 (AST) Received: from www.schrievkrom.de (port-212-202-240-110.static.qsc.de [212.202.240.110]) by svr2.postgresql.org (Postfix) with SMTP id 3E9EDF0B05 for ; Wed, 16 Nov 2005 21:41:35 +0000 (GMT) Received: from pD9FB3E23.dip.t-dialin.net ([217.251.62.35]) by www.schrievkrom.de id 67 ; Wed, 16 Nov 2005 22:41:28 +0100 Message-ID: <67.22.41.28.16.11.2005@www.schrievkrom.de> Date: Wed, 16 Nov 2005 22:41:26 +0100 From: Marten Feldtmann Organization: Privat User-Agent: Mozilla Thunderbird 1.0.6 (Windows/20050716) X-Accept-Language: de-DE, de, en-us, en MIME-Version: 1.0 To: pgsql-odbc@postgresql.org Subject: Re: Windows, ODBC drivers and strange points ... References: <4348F935.8030506@t-online.de> In-Reply-To: <4348F935.8030506@t-online.de> Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0 required=5 tests=[none] X-Spam-Score: 0 X-Spam-Level: X-Archive-Number: 200511/175 X-Sequence-Number: 6411 Perhaps you might remember my tests with PostgreSQL and IBm VisualAge Smalltalk. I mentioned my problems with column lengths and stuff like this. I still testing (from time to time) with the 8.0.3 database and use the newest 8.01.00.03 libpq ODBC drivers and now the situation is getting worse :-(((( IBM Smalltalk is now not able to get the correct column size for strings any more. I always get either 254 bytes or 508 bytes as column size. We have a table like: create table "TPERSON" ("ALLCSTVIEW" CHAR(1) .... Now IBM Smalltalk calls OdbcSQLDescribeCol and gets 254 for this column as size in the return parameter cbPrecision. And the alternate call via OdbcSQLColAttribute with parameter Sql_Column_Lengthreturns 508. Actually this is true for ALL string columns The PostgreSQL drivers seem strange for me ... I've done work with other database systems via this ODBC library, but PostgreSQL does not give me any real success .... If anyone has any help .... Marten > > > b) All strings returned by the ODBC driver are defined > in a buffer, which is offered to the ODBC subsystem > as a string doubled in size - though I told the > databaase NOT to create a UNICODE db. > > An example: a column has the result type char(15). The > ODBC drivers put the result of this column into a > memory with a size of 30 characters. > > The ODBC subsystem now thinks: fine - I've a character > column with size 30 and creates a string 30 characters > long and one gets 15 corrects characters and 15 "0" (null) > bytes. > > I've never seen this behaviour with other ODBC drivers > I've used so far, therefore I think, this is pretty > strange behaviour. > > I'm using the 8.0.3 database and the 8.0.1.2 drivers. > > Any ideas ??? > > > Marten Feldtmann > > ---------------------------(end of broadcast)--------------------------- > TIP 1: if posting/reading through Usenet, please send an appropriate > subscribe-nomail command to majordomo@postgresql.org so that your > message can get through to the mailing list cleanly > > -- Marten Feldtmann - Germany - Software Development Information regarding VA Smalltalk and DMS-system "MSK - Mien Schrievkrom" at: www.schrievkrom.de