Re: [PATCH] regexp_positions ( string text, pattern text, flags text ) → setof int4range[]

From: "Joel Jacobson" <joel(at)compiler(dot)org>
To: "Pavel Stehule" <pavel(dot)stehule(at)gmail(dot)com>
Cc: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "Mark Dilger" <mark(dot)dilger(at)enterprisedb(dot)com>, "Postgres hackers" <pgsql-hackers(at)lists(dot)postgresql(dot)org>, "Andreas Karlsson" <andreas(at)proxel(dot)se>, "David Fetter" <david(at)fetter(dot)org>
Subject: Re: [PATCH] regexp_positions ( string text, pattern text, flags text ) → setof int4range[]
Date: 2021-03-09 10:24:46
Message-ID: 1e68e062-90bb-4359-874a-ebd56ae6148f@www.fastmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Mar 9, 2021, at 10:18, Pavel Stehule wrote:
> What do you mean?
>> More than one unnest() in the same query, e.g. SELECT unnest(..), unnest(..)?
>
> you can do unnest(array1, array2, ...)

Right, I had forgotten about that variant.

But isn't this a bit surprising then:

\df unnest
List of functions
Schema | Name | Result data type | Argument data types | Type
------------+--------+------------------+----------------------------------------------------------------------------------+------
pg_catalog | unnest | SETOF anyelement | anyarray | func
pg_catalog | unnest | SETOF record | tsvector tsvector, OUT lexeme text, OUT positions smallint[], OUT weights text[] | func
(2 rows)

Should there be an entry there showing the VARIADIC anyelement version as well?

I know it's a documented feature, but \df seems out-of-sync with the docs.

/Joel

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Magnus Hagander 2021-03-09 10:25:28 Re: PROXY protocol support
Previous Message Markus Wanner 2021-03-09 10:11:10 Re: Make stream_prepare an optional callback