Re: regexp_matches and regexp_split are inconsistent

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Stephan Szabo <sszabo(at)megazone(dot)bigpanda(dot)com>
Cc: pgsql-hackers(at)postgreSQL(dot)org
Subject: Re: regexp_matches and regexp_split are inconsistent
Date: 2007-08-13 01:20:03
Message-ID: 12786.1186968003@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Stephan Szabo <sszabo(at)megazone(dot)bigpanda(dot)com> writes:
> On Fri, 10 Aug 2007, Tom Lane wrote:
>> Is this what we want? Arguably regexp_split is doing the most
>> reasonable thing for its intended usage, but the strict definition of
>> regexp matching seems to require what regexp_matches does. I think
>> we need to either change one function to match the other, or else
>> document the inconsistency.

> I'm not sure how many languages do this, but at least perl seems to work
> similarly, which makes me guess that it's probably similar in a bunch of
> languages. If it is, then we should probably just document the
> inconsistency.

The Perl precedent is good enough for me. Documented...

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Devrim GÜNDÜZ 2007-08-13 06:33:05 Maximum row size
Previous Message Tom Lane 2007-08-12 17:54:04 Re: Interesting misbehavior of repalloc()