Re: postgres 7.2.1 parse bug - Mailing list pgsql-general

From Amin Abdulghani
Subject Re: postgres 7.2.1 parse bug
Date
Msg-id web-728915@quantiva.com
Whole thread Raw
In response to postgres 7.2.1 parse bug  (Amin Abdulghani <amin@quantiva.com>)
List 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@quantiva.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


pgsql-general by date:

Previous
From: Matthew Kirkwood
Date:
Subject: Re: tsearch - Regression tests fail
Next
From: Patrick Nelson
Date:
Subject: Importing data