Only one version can be installed when using extension_control_path

From: Pierrick <pierrick(dot)chovelon(at)dalibo(dot)com>
To: pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Only one version can be installed when using extension_control_path
Date: 2025-09-05 14:22:14
Message-ID: 8f5a0517-1cb8-4085-ae89-77e7454e27ba@dalibo.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

If the same extension is in two different paths mentioned in
extension_control_path,
it is impossible to install the version of the last one.

postgres=# show extension_control_path ;
                           extension_control_path
-----------------------------------------------------------------------------
 $system:/extensions/meilleureextension/share:/extensions/monextension/share
(1 row)

postgres=# select * from pg_available_extensions where name like '%mon%';
     name     | default_version | installed_version |    comment
--------------+-----------------+-------------------+---------------
 monextension | 2.0             |                   | Meilleure
 monextension | 1.0             |                   | Mon extension

(2 rows)

postgres=# create extension monextension version "1.0" ;
ERROR:  extension "monextension" has no installation script nor update path for version "1.0"

postgres=# create extension monextension ;
CREATE EXTENSION
postgres=# select * from pg_available_extensions where name like '%mon%';
name | default_version | installed_version | comment
--------------+-----------------+-------------------+---------------
monextension | 2.0 | 2.0 | Meilleure
monextension | 1.0 | 2.0 | Mon extension

Don't you think that the command

create extension monextension version "1.0" ;

should be accepted by checking in all paths ?

Pierrick,

Browse pgsql-hackers by date

  From Date Subject
Next Message Nazir Bilal Yavuz 2025-09-05 14:23:58 Re: Differential Code Coverage report for Postgres
Previous Message Tom Lane 2025-09-05 14:08:10 Re: Appetite for syntactic sugar to match result set columns to UDT fields?