Re: [19] Proposal: function markers to indicate collation/ctype sensitivity

From: Jeff Davis <pgsql(at)j-davis(dot)com>
To: Peter Eisentraut <peter(at)eisentraut(dot)org>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: [19] Proposal: function markers to indicate collation/ctype sensitivity
Date: 2025-06-05 20:47:22
Message-ID: 8a0e1fd640ab388fdb5b80890e4f39892b62b7b4.camel@j-davis.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, 2025-06-05 at 10:12 +0200, Peter Eisentraut wrote:
> But I would consider making this one setting
> with multiple values instead of multiple boolean settings.

While we're at it, CTYPE is not very descriptive for a user-facing
name. And COLLATE has become overloaded (expression clause,
pg_collation object, ordering, or the superset of behaviors that
includes CTYPE). Let's consider more user-friendly naming for the
markers:

CASE: lower/upper/initcap/fold behavior
CLASS: char classifications such as [[:punct:]]
ORDER: comparisons

Internally, at least for the foreseeable future, CASE and CLASS would
be the same. They'd just be different markers to record the user's
intent.

Also, we could use keywords in the DDL syntax, or we could use a new
options syntax, or a comma-separated list as a string literal to
specify the markers. I don't have a strong opinion on which route to
take, but I chose the above names from existing keywords so we wouldn't
have to add any.

Regards,
Jeff Davis

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Ilia Evdokimov 2025-06-05 20:47:23 Re: track generic and custom plans in pg_stat_statements
Previous Message Robert Treat 2025-06-05 20:14:32 Re: [PATCH] Re: Proposal to Enable/Disable Index using ALTER INDEX