Re: [HACKERS] About the behavior of array_length() for empty array

2012-04-09 Thread Robert Haas
On Thu, Apr 5, 2012 at 8:35 PM, iihero wrote: > From this point of view, seems N dimensions of empty array all are > equivalent. Yes. It's effectively viewed as a 0-dimensional array. > Is there standard definition of this behavior? No. Multi-dimensional arrays are a PostgreSQL extension. --

[HACKERS] About the behavior of array_length() for empty array

2012-04-05 Thread iihero
postgres=# select '{}'::integer[] = array[[]]::integer[][]; ?column? -- t postgres=# select '{}'::integer[] = array[[[]]]::integer[][][]; ?column? -- t From this point of view, seems N dimensions of empty array all are equivalent. But the result of array_length of them always