Re: Cluster wide option to control symbol case folding

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Lewis, Ian \(Microstar Laboratories\)" <ilewis(at)mstarlabs(dot)com>
Cc: "Robert Haas" <robertmhaas(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Cluster wide option to control symbol case folding
Date: 2017-01-04 00:39:16
Message-ID: 22900.1483490356@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

"Lewis, Ian \(Microstar Laboratories\)" <ilewis(at)mstarlabs(dot)com> writes:
> One idea, which would likely be harder to implement on the server, but
> that would have less impact on third party tools and libraries, would be
> to configure case folding on a session basis.

There are a couple of problems even with that:

1. All the sessions have to share the same catalog state, which greatly
restricts what you could do.

2. If the folding mode is chosen through a GUC variable, which is
certainly what people would expect, then it turns out that it breaks
client libraries/applications *anyway*, because an installation-wide
setting could impose itself on a client that hadn't asked for it.
So you have to update everything at least to the extent of teaching it
to turn off setting X when talking to server versions >= Y. And for
libraries, that isn't a great solution because then they're incompatible
with applications that wanted another setting. The notion that the
client side is a monolithic chunk doesn't withstand scrutiny; really
there's usually a stack of code over there, and it all has to cope
with the SQL semantics we expose.

Point #2 was really the lesson that we learned the hard way with the
autocommit fiasco. We'd thought going into it that client-side code
could be updated only when somebody wanted to use the new behavior,
and it took awhile to absorb the fact that much code would be forced
to deal with the behavior whether it wanted to or not.

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Michael Paquier 2017-01-04 00:45:52 Re: pg_authid.rolpassword format (was Re: Password identifiers, protocol aging and SCRAM protocol)
Previous Message Tom Lane 2017-01-04 00:21:36 Re: Unusable SP-GiST index