Re: postgres 7.2.1 parse bug

From: Amin Abdulghani <amin(at)quantiva(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: postgres 7.2.1 parse bug
Date: 2002-07-29 17:22:25
Message-ID: web-728915@quantiva.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi,

We use Postgres extensively for our applications
and it works great for us. Recently we have hit an
array bug ( at least to us it seems like a bug :) )
posted down. The bug appears to have
been introduced in 7.2.1. Our applications use array
columns extensively, so its of concern to us. We want to
make sure this bug hasn't compromised other parts of the
array code. Would it be correct to assume that this
is isolated and that the rest of the array code remains
stable?

Thanks..
Amin
On Thu, 25 Jul 2002 16:01:00 -0400
Amin Abdulghani<amin(at)quantiva(dot)com> wrote:
>Hi,
>
>Apparently there seems to be a parsing bug in 7.2.1 (
>though it seems to be OK in 7.2)when inserting into array
>columns. The bug seems to be that if an
>array element is quoted with "" followed by spaces before
>the comma (for the next element), the extra space becomes
>part of the text for the element.
>
>As an example consider the following (testa is a table
>with
>a single column data of type text[])
>(Note the space after bob and space after the first null
>string.)
>
>netwait_db=# insert into testa values('{"bob" ,"moo",""
>,"","theend"}');
>INSERT 22317950 1
>netwait_db=# insert into testa
>values('{"Bob","moo","","","theend"}');
>INSERT 22317953 1
>netwait_db=# select * from testa;
> data
>----------------------------
> {"bob ",moo," ","",theend}
> {Bob,moo,"","",theend}
>(2 rows)
>
>netwait_db=#
>
>Thanks..
>Amin

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Tom Harden 2002-07-29 17:23:30 JDBC problems
Previous Message Matthew Kirkwood 2002-07-29 17:17:39 Re: tsearch - Regression tests fail