Adding clarification on extension_control_path when extension is present in multiple folders

From: Pierrick <pierrick(dot)chovelon(at)dalibo(dot)com>
To: pgsql-docs(at)lists(dot)postgresql(dot)org
Subject: Adding clarification on extension_control_path when extension is present in multiple folders
Date: 2025-09-05 13:53:09
Message-ID: 211e8d61-7fea-4eb2-892a-c3c1f32e3a89@dalibo.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-docs

When playing with the new GUC extension_control_path, I found that the
paths are evaluated one by one
(like search_path)and if an extension is present in multiple paths, only
the on in the first path
will be considered.I think this is totally fine, but I'd like to adda
documentation patch to explain
this (attached file).

What do you think ?

Pierrick,

Here is an example to understand that I can only create extension in
version 2.0.

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=# 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
(2 rows)

Attachment Content-Type Size
0001-Add-clarification-on-extension_control_path.patch text/x-patch 950 bytes

Browse pgsql-docs by date

  From Date Subject
Previous Message PG Doc comments form 2025-09-04 22:32:44 SELECT List with/without parentheses