Andrew Dunstan <[email protected]> writes:
> Grzegorz Jaskiewicz wrote:
>> On 1 Mar 2009, at 00:52, Andrew Dunstan wrote:
>>> We seem to have acquired a cardinality() function with almost no
>>> discussion, and it has semantics that are a bit surprising to me. I
>>> should have thought cardinality(array) would be the total number of
>.> elements in the array. Instead, it seems it is a synonym for
>>> array_length(array,1). Is that *really* what the standard says?
>> Standart just says something like:
>> cardinality (a collection):
>> - The number of elements in that collection.
The standard doesn't have multi-dimensional arrays, so it's entirely
possible that somewhere in it there is wording that makes cardinality()
equivalent to the length of the first dimension. But I concur with
Andrew that this is flat wrong when extended to m-d arrays.
regards, tom lane
--
Sent via pgsql-hackers mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers