| From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
|---|---|
| To: | "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com> |
| Cc: | Mark Hill <Mark(dot)Hill(at)sas(dot)com>, pgsql-general <pgsql-general(at)lists(dot)postgresql(dot)org>, Phil Rau <Phil(dot)Rau(at)sas(dot)com>, Michael King <Michael(dot)King(at)sas(dot)com>, Ashley Stephens <Ashley(dot)Stephens(at)sas(dot)com> |
| Subject: | Re: Error Creating pgcrypto Extension |
| Date: | 2026-09-18 00:05:02 |
| Message-ID: | 947662.1789689902@sss.pgh.pa.us |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
"David G. Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com> writes:
> On Thu, Sep 17, 2026 at 3:25 PM Mark Hill <Mark(dot)Hill(at)sas(dot)com> wrote:
>> We are trying to run this code in Postgres 18.6:
>> *1) Should pgcrytpo—1.3.sql be trying to create gen_random_uuid() if/when
>> it already exists?*
> It's not expecting to be installed in the pg_catalog schema since it is an
> extension. Extensions don't usually conditionally install their components.
Yeah. As of now, installing pgcrypto into pg_catalog is unsupported.
>> *2) given what’s in pgcrypto.control should there be a pgcrypto—1.4.sql
>> file?*
> The pattern of a base full install and then incremental update scripts is
> supported.
Installing 1.3 and then updating to a hypothetical 1.4 wouldn't work
anyway in this scenario, because installing 1.3 would fail.
We could perhaps decide that pgcrypto doesn't need to provide
gen_random_uuid anymore; maybe that backwards-compatibility hack
has served its time. But I'm not sure if removing the function
would break anybody. If we did go that way, we'd need to provide
a 1.3-to-1.4 update script that drops the function, and also a
pgcrypto--1.4 install script that rolls up all the prior updates
so that it never tries to create gen_random_uuid in the first place.
On the whole, seeing that installing pgcrypto into pg_catalog has
not worked since v13 and there's been hardly any complaints about
that, I'm not sure that we should risk breaking working setups to
allow it.
regards, tom lane
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Daniel Gustafsson | 2026-09-18 09:43:38 | Re: Error Creating pgcrypto Extension |
| Previous Message | David G. Johnston | 2026-09-17 21:11:52 | Re: Error Creating pgcrypto Extension |