is array bug? (array[][])[] = NULL - Mailing list pgsql-bugs

From Pavel Stehule
Subject is array bug? (array[][])[] = NULL
Date
Msg-id Pine.LNX.4.44.0406041443080.28450-100000@kix.fsv.cvut.cz
Whole thread Raw
Responses Re: is array bug? (array[][])[] = NULL
List pgsql-bugs
Hello

   I am not sure so decrease of array dimensions is regular operations.
But following code dont make syntax error.

create or replace function xxx() returns bool as $$
declare v1 varchar[]; v2 varchar[][];
begin
  v2 := array[array[1,2], array[3,4]];
  raise notice 'v2 %', v2;
  v1 := v2[1];
  raise notice 'v1 %', v1;
  return 't';
end; $$ language plpgsql;

I expect v1 = [1,2], but v1 is null.
What is wrong?

Regards
Pavel Stehule

pgsql-bugs by date:

Previous
From: Tarhon-Onu Victor
Date:
Subject: Re: Select (str)::FLOAT8 BUG
Next
From: contact
Date:
Subject: build postgresql-7.4.2 fails: FATAL: semctl(35, 16, SETVAL, 536) failed: Inv,alid argument