array_length(anyarray)

From: Marko Tiikkaja <marko(at)joh(dot)to>
To: PostGreSql hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: array_length(anyarray)
Date: 2013-12-18 20:27:54
Message-ID: 52B2054A.8010907@joh.to
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

Attached is a patch to add support for array_length(anyarray), which
only works for one-dimensional arrays, returns 0 for empty arrays and
complains if the array's lower bound isn't 1. In other words, does the
right thing when used with the arrays people use 99% of the time.

I'll add this to the next commit fest, but feel free to discuss it
before that.

Regards,
Marko Tiikkaja

Attachment Content-Type Size
array_length.patch text/plain 5.5 KB

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Kevin Grittner 2013-12-18 20:39:53 Re: [PATCH] SQL assertions prototype
Previous Message Dong Ye 2013-12-18 20:27:08 Re: 9.3 regression with dbt2