From milton.siqueira@mapcardoso.com.br Tue Jan 10 14:29:51 2006 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 C458A9DCAC4 for ; Tue, 10 Jan 2006 10:29:51 -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 10995-02-10 for ; Tue, 10 Jan 2006 10:29:54 -0400 (AST) X-Greylist: delayed 00:06:39.31093 by SQLgrey- Received: from mailer3.internext.com.br (unknown [200.241.116.2]) by postgresql.org (Postfix) with SMTP id B6F719DCC26 for ; Tue, 10 Jan 2006 09:09:09 -0400 (AST) Received: (qmail 84172 invoked by uid 1127); 10 Jan 2006 13:02:31 -0000 Received: from milton.siqueira@mapcardoso.com.br by mailer3.internext.com.br by uid 1002 with qmail-scanner-1.22 (uvscan: v4.2.40/v4367. spamassassin: 2.50. Clear:RC:1(200.208.241.186):. Processed in 4.712548 secs); 10 Jan 2006 13:02:31 -0000 Received: from b04ip186.internext.com.br (HELO map0502) (200.208.241.186) by mailer3.internext.com.br with SMTP; 10 Jan 2006 13:02:26 -0000 Message-ID: <001c01c615e6$0f4ca360$24000aaa@mapcardoso.com.br> From: "Milton" To: "pgsql-odbc" Subject: =?iso-8859-1?Q?I_can=B4t_read_the_data_in_the_second_time?= Date: Tue, 10 Jan 2006 09:02:03 -0400 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_0019_01C615C4.85EBBC30" X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4927.1200 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4927.1200 X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.001 required=5 tests=[HTML_MESSAGE=0.001] X-Spam-Score: 0.001 X-Spam-Level: X-Archive-Number: 200601/87 X-Sequence-Number: 6902 This is a multi-part message in MIME format. ------=_NextPart_000_0019_01C615C4.85EBBC30 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable There are cases than i can=B4t read the data one more time. See the VB example below: =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D dim rdoQuery as rdoResultset dim strValue as string set rdoQuery =3D connection.OpenResultset("SELECT '1' || '2' AS test", = rdOpenKeyset, rdConcurReadOnly) strValue =3D rdoQuery(0) ' Value is '12' strValue =3D rdoQuery(0) ' ERROR HERE: Invalid user of Null =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D The similar example work in the others DB (ORACLE, SQL SERVER, INFORMIX) Is it a bug in the pgsql-odbc? P.S. : I have a program to test it, if someone would like to use this, = notify me, ok!!? ------=_NextPart_000_0019_01C615C4.85EBBC30 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
There are cases than i can=B4t read the = data one more=20 time.
See the VB example below:
 
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
dim rdoQuery as = rdoResultset
dim strValue as string
 
set rdoQuery =3D = connection.OpenResultset("SELECT '1'=20 || '2' AS test", rdOpenKeyset, rdConcurReadOnly)
 
strValue =3D rdoQuery(0) ' Value is = '12'
strValue =3D rdoQuery(0) ' ERROR HERE: = Invalid user=20 of Null

 

=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D

 

The=20 similar example work in the others DB (ORACLE, SQL SERVER, = INFORMIX)

 

Is it a=20 bug in the pgsql-odbc?

 

P.S. : I=20 have a program to test it, if someone would like to use this, notify me, = ok!!?

------=_NextPart_000_0019_01C615C4.85EBBC30-- From luf@pzkagis.cz Tue Jan 10 21:06:00 2006 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 E91579DC83C for ; Tue, 10 Jan 2006 17:06:00 -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 93926-04 for ; Tue, 10 Jan 2006 17:06:01 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey- Received: from smtp.pzkagis.cz (gis6.netbox.cz [83.240.30.214]) by postgresql.org (Postfix) with ESMTP id 7D2459DC816 for ; Tue, 10 Jan 2006 17:05:57 -0400 (AST) Received: from soptik.pzkagis.cz (localhost.localdomain [127.0.0.1]) by smtp.pzkagis.cz (8.13.1/8.13.1) with ESMTP id k0AL5p6T008150; Tue, 10 Jan 2006 22:05:51 +0100 Received: (from luf@localhost) by soptik.pzkagis.cz (8.13.1/8.13.1/Submit) id k0AL5pZQ008149; Tue, 10 Jan 2006 22:05:51 +0100 Date: Tue, 10 Jan 2006 22:05:51 +0100 From: Ludek Finstrle To: Milton Cc: pgsql-odbc Subject: Re: I can't read the data in the second time Message-ID: <20060110210551.GA8098@soptik.pzkagis.cz> References: <001c01c615e6$0f4ca360$24000aaa@mapcardoso.com.br> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <001c01c615e6$0f4ca360$24000aaa@mapcardoso.com.br> User-Agent: Mutt/1.4.1i X-Virus-Scanned: ClamAV version 0.87.1, clamav-milter version 0.87 on smtp.pzkagis.cz X-Virus-Status: Clean X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.068 required=5 tests=[AWL=0.068] X-Spam-Score: 0.068 X-Spam-Level: X-Archive-Number: 200601/95 X-Sequence-Number: 6910 > There are cases than i canīt read the data one more time. > See the VB example below: > > ================================ > dim rdoQuery as rdoResultset > dim strValue as string > > set rdoQuery = connection.OpenResultset("SELECT '1' || '2' AS test", rdOpenKeyset, rdConcurReadOnly) > > strValue = rdoQuery(0) ' Value is '12' > strValue = rdoQuery(0) ' ERROR HERE: Invalid user of Null > > > ================================ > > The similar example work in the others DB (ORACLE, SQL SERVER, INFORMIX) No. Same situation doesn't work againist MSSQL. When you try "SELECT column FROM table1" where column is type longvarchar it fails againist MSSQL: =========================10.1. 2006 22:55:41========================= Access Column 'text' failed Error: 40002 - S1109: [Microsoft][SQL Native Client]Invalid cursor position rdoErrors: 0 - S1109: [Microsoft][SQL Native Client]Invalid cursor position =========================10.1. 2006 22:55:41========================= =========================10.1. 2006 22:55:40========================= Query opened Command to Open SQL: OpenResultset('select codi as text from table1', rdOpenKeyset, rdConcurReadOnly) =========================10.1. 2006 22:55:40========================= PgSQL backend handles varchar as text in functions. I don't know how to change it. We don't know text type size. We can't get it from backend (at least I don't know how). So ADO choose SQLGetData method to get it. There is limitation to not call SQLGetData after whole data is getting from column. > Is it a bug in the pgsql-odbc? I think it's not a bug in psqlodbc. Workarounds: 1) retype column from text to varchar explicitely 2) turn off Text as LongVarchar in Datasource settings I hope it helps or someone point that I make mistake somewhere. Regards, Luf From milton.siqueira@mapcardoso.com.br Tue Jan 10 21:39:44 2006 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 62E959DC8A8 for ; Tue, 10 Jan 2006 17:39:44 -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 97541-09 for ; Tue, 10 Jan 2006 17:39:45 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey- Received: from mailer3.internext.com.br (unknown [200.241.116.2]) by postgresql.org (Postfix) with SMTP id 155DE9DC8AA for ; Tue, 10 Jan 2006 17:39:38 -0400 (AST) Received: (qmail 22655 invoked by uid 1127); 10 Jan 2006 21:39:39 -0000 Received: from milton.siqueira@mapcardoso.com.br by mailer3.internext.com.br by uid 1002 with qmail-scanner-1.22 (uvscan: v4.2.40/v4367. spamassassin: 2.50. Clear:RC:1(200.208.241.186):. Processed in 3.579136 secs); 10 Jan 2006 21:39:39 -0000 Received: from b04ip186.internext.com.br (HELO map0502) (200.208.241.186) by mailer3.internext.com.br with SMTP; 10 Jan 2006 21:39:35 -0000 Message-ID: <005e01c6162e$4dcec120$24000aaa@mapcardoso.com.br> From: "Milton" To: "Ludek Finstrle" Cc: "pgsql-odbc" References: <001c01c615e6$0f4ca360$24000aaa@mapcardoso.com.br> <20060110210551.GA8098@soptik.pzkagis.cz> Subject: Re: I can't read the data in the second time Date: Tue, 10 Jan 2006 17:39:09 -0400 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 8bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4927.1200 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4927.1200 X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.268 required=5 tests=[AWL=0.268] X-Spam-Score: 0.268 X-Spam-Level: X-Archive-Number: 200601/97 X-Sequence-Number: 6912 > 2) turn off Text as LongVarchar in Datasource settings Itīs work only the last version (isnīt 08.01.06) than you were send to me. This version solve all my problems... Thanks, Luf!!! ----- Original Message ----- From: "Ludek Finstrle" To: "Milton" Cc: "pgsql-odbc" Sent: Tuesday, January 10, 2006 5:05 PM Subject: Re: [ODBC] I can't read the data in the second time > There are cases than i canīt read the data one more time. > See the VB example below: > > ================================ > dim rdoQuery as rdoResultset > dim strValue as string > > set rdoQuery = connection.OpenResultset("SELECT '1' || '2' AS test", rdOpenKeyset, rdConcurReadOnly) > > strValue = rdoQuery(0) ' Value is '12' > strValue = rdoQuery(0) ' ERROR HERE: Invalid user of Null > > > ================================ > > The similar example work in the others DB (ORACLE, SQL SERVER, INFORMIX) No. Same situation doesn't work againist MSSQL. When you try "SELECT column FROM table1" where column is type longvarchar it fails againist MSSQL: =========================10.1. 2006 22:55:41========================= Access Column 'text' failed Error: 40002 - S1109: [Microsoft][SQL Native Client]Invalid cursor position rdoErrors: 0 - S1109: [Microsoft][SQL Native Client]Invalid cursor position =========================10.1. 2006 22:55:41========================= =========================10.1. 2006 22:55:40========================= Query opened Command to Open SQL: OpenResultset('select codi as text from table1', rdOpenKeyset, rdConcurReadOnly) =========================10.1. 2006 22:55:40========================= PgSQL backend handles varchar as text in functions. I don't know how to change it. We don't know text type size. We can't get it from backend (at least I don't know how). So ADO choose SQLGetData method to get it. There is limitation to not call SQLGetData after whole data is getting from column. > Is it a bug in the pgsql-odbc? I think it's not a bug in psqlodbc. Workarounds: 1) retype column from text to varchar explicitely 2) turn off Text as LongVarchar in Datasource settings I hope it helps or someone point that I make mistake somewhere. Regards, Luf ---------------------------(end of broadcast)--------------------------- TIP 4: Have you searched our list archives? http://archives.postgresql.org From luf@pzkagis.cz Tue Jan 10 22:04:02 2006 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 B7EBD9DC8E1 for ; Tue, 10 Jan 2006 18:04:02 -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 03252-09 for ; Tue, 10 Jan 2006 18:04:04 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey- Received: from smtp.pzkagis.cz (gis6.netbox.cz [83.240.30.214]) by postgresql.org (Postfix) with ESMTP id 285BD9DC8A8 for ; Tue, 10 Jan 2006 18:03:59 -0400 (AST) Received: from soptik.pzkagis.cz (localhost.localdomain [127.0.0.1]) by smtp.pzkagis.cz (8.13.1/8.13.1) with ESMTP id k0AM3rK2008375; Tue, 10 Jan 2006 23:03:53 +0100 Received: (from luf@localhost) by soptik.pzkagis.cz (8.13.1/8.13.1/Submit) id k0AM3rHr008374; Tue, 10 Jan 2006 23:03:53 +0100 Date: Tue, 10 Jan 2006 23:03:53 +0100 From: Ludek Finstrle To: Milton Cc: pgsql-odbc Subject: Re: I can't read the data in the second time Message-ID: <20060110220353.GA8353@soptik.pzkagis.cz> References: <001c01c615e6$0f4ca360$24000aaa@mapcardoso.com.br> <20060110210551.GA8098@soptik.pzkagis.cz> <005e01c6162e$4dcec120$24000aaa@mapcardoso.com.br> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <005e01c6162e$4dcec120$24000aaa@mapcardoso.com.br> User-Agent: Mutt/1.4.1i X-Virus-Scanned: ClamAV version 0.87.1, clamav-milter version 0.87 on smtp.pzkagis.cz X-Virus-Status: Clean X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.069 required=5 tests=[AWL=0.069] X-Spam-Score: 0.069 X-Spam-Level: X-Archive-Number: 200601/100 X-Sequence-Number: 6915 > > 2) turn off Text as LongVarchar in Datasource settings > > Itīs work only the last version (isnīt 08.01.06) than you were send to me. I know. There was bug in Text as LongVarchar option. Someone else report it in the bug tracker ;-) I has solved it yesterday. > This version solve all my problems... Nice to hear. I'll close the bug-entry. Regards, Luf