Skip site navigation (1) Skip section navigation (2)

Re: BUG #2839: after record with NULL field, query result is wrong

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Vladimir" <dvs(at)fon(dot)kamchatka(dot)ru>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #2839: after record with NULL field, query result is wrong
Date: 2006-12-26 19:28:41
Message-ID: 27183.1167161321@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-bugs
"Vladimir" <dvs(at)fon(dot)kamchatka(dot)ru> writes:
> create table tst (a int[]);
> insert into tst values ('{1}'); -- (1)
> insert into tst values (null);
> insert into tst values ('{2}'); -- (3)
> select z.a from tst z where exists (select 1 from 
> (
> select generate_series(1,1) as s,* from (select z.a as arr0) qq
> ) q
> where (q.arr0[q.s] is null)  );

Hmm, surprising this hasn't been found before, because the underlying
bug has been around for a long time :-(.  Fix committed --- thanks for
the report!

			regards, tom lane

In response to

pgsql-bugs by date

Next:From: john lyssyDate: 2006-12-26 20:00:23
Subject: BUG #2866: cast varchar to decimal failure
Previous:From: Tom LaneDate: 2006-12-26 16:57:46
Subject: Re: BUG #2836: SPI_execute_plan failed on pl/pgsql function that worked on 8.1

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group