Re: citext function overloads for text parameters

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Shay Rojansky <roji(at)roji(dot)org>
Cc: Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: citext function overloads for text parameters
Date: 2018-05-06 15:31:32
Message-ID: 8491.1525620692@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Shay Rojansky <roji(at)roji(dot)org> writes:
> Do you think it would be appropriate to simply add an strpos(citext, text)
> overload to the extension to make sure this behaves more as expected? If so
> I can try to submit a patch at some point.

To me, if there's both a citext and a text parameter, then it's simply
unclear which behavior is wanted; I do not think there's a principled
argument that it should be case-insensitive. Thus, adding a function
to reverse the current interpretation would amount to breaking some
currently-working apps to favor others that currently don't work.
Doesn't really sound like a net gain.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Yura Sokolov 2018-05-06 15:38:23 Re: [HACKERS] Clock with Adaptive Replacement
Previous Message Andrew Dunstan 2018-05-06 13:34:52 perlcritic and perltidy