[postgis-tickets] [PostGIS] #3892: Review safety and behavior of CREATE EXTENSION from UNPACKAGED

PostGIS trac at osgeo.org
Mon Oct 9 23:05:49 PDT 2017


#3892: Review safety and behavior of CREATE EXTENSION from UNPACKAGED
----------------------+---------------------------
  Reporter:  strk     |      Owner:  pramsey
      Type:  task     |     Status:  new
  Priority:  high     |  Milestone:  PostGIS 2.4.1
 Component:  postgis  |    Version:  2.4.x
Resolution:           |   Keywords:
----------------------+---------------------------

Comment (by robe):

 In all cases, the unpackaged would fail if it tries to add a type,
 function, agg that is not installed so I think the worse case scenario of
 your lib pointing at 2.2 but your unpackaged stamps it as 2.4 is accounted
 for

 Worst case is they don't have an installation of what they came from so no
 unpackaged script for them to run so they are stuck unpackaged because the
 only ones available error out.

 If the unpackaged actually works, then what postgresql thinks you are
 running is not what you have installed.

 .

 For this case

 {{{
 SELECT postgis_full_version();
 }}}

 Would show the inconsistency.  However postgis_full_version() doesn't tell
 them what to do if their postgis extension say they are at 2.4.1 but they
 are really at 2.4.0.

 So postgis_full_version() whould need to look at the
 pg_available_extensions.installed_version and compare it to what
 postgis_lib_version() says and if it's different and
 pg_available_extensions.installed_version =
 pg_available_extensions.default_version

 tell them the need to run


 {{{
 ALTER EXTENSION postgis UPDATE TO "2.4.1next";

 ALTER EXTENSION postgis UPDATE TO "2.4.1";

 }}}

--
Ticket URL: <https://trac.osgeo.org/postgis/ticket/3892#comment:5>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.


More information about the postgis-tickets mailing list