[BUGS] Damn bug!

2000-07-20 Thread Bernie Huang
Hi, Sorry for the subject, but it is driving me crazy that I spend my entire morning searching for this little bug. =( Well, I found it. I have a field using array (eg; col1 text[]) in Postgres, and it's a list of attributes. (eg; {"hi","hello","whatever","Empty",...}) When I tried to update

Re: [BUGS] Damn bug!

2000-07-20 Thread Andrew McMillan
Bernie Huang wrote: > > I have a field using array (eg; col1 text[]) in Postgres, and it's a > list of attributes. (eg; {"hi","hello","whatever","Empty",...}) > > When I tried to update elements in the array via PHP script, > > $query = "update table > set col1[1]='$var1', >

Re: [BUGS] Damn bug!

2000-07-20 Thread Jan Wieck
Bernie Huang wrote: [Charset iso-8859-15 unsupported, filtering to ASCII...] > Hi, > > Sorry for the subject, but it is driving me crazy that I spend my entire > morning searching for this little bug. =( > > Well, I found it. > > I have a field using array (eg; col1 text[]) in Postgres, and it's

Re: [BUGS] Damn bug!

2000-07-20 Thread Tom Lane
[EMAIL PROTECTED] (Jan Wieck) writes: > pgsql=# update t1 set a[1] = 'new', a[2] = 'Empty'; > UPDATE 1 > pgsql=# select * from t1; >a > --- > {"new","bar"} > (1 row) > Don't know where this might happen, but it's int

Re: [BUGS] Damn bug!

2000-07-20 Thread Tom Lane
I wrote: > I think what we're seeing here is evidence that it really doesn't work. > Possibly there's some hack in array_set that overwrites the source > data (which it shouldn't be doing, in any case!) when the data length > doesn't need to change. Needs more digging to understand in detail...