Re: [PATCH] Add citext_pattern_ops to citext contrib module

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Alexey Chernyshov <a(dot)chernyshov(at)postgrespro(dot)ru>
Cc: PostgreSQL-Dev <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [PATCH] Add citext_pattern_ops to citext contrib module
Date: 2017-09-12 16:59:20
Message-ID: 3469.1505235560@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Alexey Chernyshov <a(dot)chernyshov(at)postgrespro(dot)ru> writes:
> The attached patch introduces citext_pattern_ops for citext extension
> type like text_pattern_ops for text type. Here are operators ~<~, ~<=~,
> ~>~, ~>=~ combined into citext_pattern_ops operator class. These
> operators simply compare underlying citext values as C strings with
> memcmp() function.

Hi Alexey,

Quick comment on this patch: recently, we've decided that having patches
replace the whole base script for an extension is too much of a
maintenance problem, especially when there are several patches in the
pipeline for the same contrib module. The new style is to provide only
a version update script (which you'd have to write anyway), and then
rely on CREATE EXTENSION to apply the old base script plus the update(s).
You can see some examples in the patch I just posted at

https://www.postgresql.org/message-id/24721.1505229713@sss.pgh.pa.us

Also, since that patch is probably going to get committed pretty soon, you
could reformulate your patch as an add-on to its citext--1.4--1.5.sql
script. We don't really need to have a separate version of the extension
for states that are intermediate between two PG major releases. Only
if your patch doesn't get in by v11 freeze would you need to make it a
separate citext--1.5--1.6.sql script.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Fabien COELHO 2017-09-12 17:08:31 Re: pgbench regression test failure
Previous Message Peter Geoghegan 2017-09-12 16:30:23 Re: Automatic testing of patches in commit fest