Re: [Review] Tests citext casts by David Wheeler.

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Ryan Bradetich" <rbradetich(at)gmail(dot)com>
Cc: "David E(dot) Wheeler" <david(at)kineticode(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [Review] Tests citext casts by David Wheeler.
Date: 2008-09-05 18:30:03
Message-ID: 29064.1220639403@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

"Ryan Bradetich" <rbradetich(at)gmail(dot)com> writes:
> Here is my review of the Test citext casts written by David Wheeler:

Thanks for reviewing. I've committed this with your suggestions and
one additional non-cosmetic change: schema-qualify names in the
bodies of the SQL functions so that they are not search_path dependent.

One thing that didn't make a lot of sense to me was the last new
function:

CREATE OR REPLACE FUNCTION translate( citext, citext, text ) RETURNS TEXT AS $$
SELECT pg_catalog.translate( pg_catalog.translate( $1::pg_catalog.text, pg_catalog.lower($2::pg_catalog.text), $3), pg_catalog.upper($2::pg_catalog.text), $3);
$$ LANGUAGE SQL IMMUTABLE STRICT;

Why is it using upper()?

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Heikki Linnakangas 2008-09-05 18:32:22 Re: Prototype: In-place upgrade v02
Previous Message Volkan YAZICI 2008-09-05 18:25:59 Re: Verbosity of Function Return Type Checks