Re: Regular expression for lower case to upper case.

Eagna <eagna@protonmail.com>

From: Eagna <eagna@protonmail.com>
To: "Peter J. Holzer" <hjp-pgsql@hjp.at>
Cc: pgsql-general@lists.postgresql.org
Date: 2022-12-10T10:57:32Z
Lists: pgsql-general
Hi, and thanks for your input,

> Tha said, the replacement string in some editors (like Vim) and some
> programming languages (like Perl) provides syntax for changing case
> (both vi(m) and Perl use \u and \U...\E for uppercasing).


This is probably why I was so frustrated - I thought that there should be an equivalent in PostgreSQL.

I was going mad trying all of these from my searches.
 
> > I know about the UPPER() and LOWER() functions and they are not what I want.

> Can you elaborate why you can't use those?


I want to index on a REGEXP_REPLACE() - I thought using lower -> upper would be a good test.

I could always have used another REGEXP_REPLACE() for my testing, but I then became "obsessed"  with the idea of using REGEXP_REPLACE() as a substitute for UPPER() - kind of an obfuscated code competition with myself! :-)

Again, thanks for your input.

E.
 
> hp