[postgis-tickets] [PostGIS] #4483: Can't upgrade from PostGIS 3.0.0alpha3 to 3.0.0alpha4 or 3.0.0alpha5dev (ST_AsGeoJSON) (was: Can't upgrade from PostGIS 3.0.0alpha3 to 3.0.0alpha4 ST_AsGeoJSON)

PostGIS trac at osgeo.org
Tue Oct 8 00:59:07 PDT 2019


#4483: Can't upgrade from PostGIS 3.0.0alpha3 to 3.0.0alpha4 or 3.0.0alpha5dev
(ST_AsGeoJSON)
----------------------+---------------------------
  Reporter:  robe     |      Owner:  pramsey
      Type:  defect   |     Status:  reopened
  Priority:  medium   |  Milestone:  PostGIS 3.0.0
 Component:  postgis  |    Version:  trunk
Resolution:           |   Keywords:
----------------------+---------------------------

Comment (by strk):

 Raul, this is what I find in the ANY--3.0.0alpha5dev.sql file:
 {{{
 -- FUNCTION ST_AsGeoJson changed argument names
 -- (pretty_print => pretty_bool) in 3.0alpha4
 SELECT _postgis_drop_function_if_needed
         (
         '@extschema@',
         'ST_AsGeoJson',
         'r record, geom_column text, maxdecimaldigits int4, pretty_print
 bool'
         );
 }}}

 Here's the log of a "manual" session to try that portion of upgrade:
 {{{
 CREATE FUNCTION _postgis_drop_function_if_needed ....

 strk=# begin;
 BEGIN
 strk=# SELECT _postgis_drop_function_if_needed
 strk-#         (
 strk(#         '@extschema@',
 strk(#         'ST_AsGeoJson',
 strk(#         'r record, geom_column text, maxdecimaldigits int4,
 pretty_print bool'
 strk(#         );
  _postgis_drop_function_if_needed
 ----------------------------------

 (1 row)

 strk=# CREATE OR REPLACE FUNCTION ST_AsGeoJson(r record, geom_column text
 DEFAULT '', maxdecimaldigits int4 DEFAULT 9, pretty_bool bool DEFAULT
 false)
 strk-#         RETURNS text
 strk-#         AS '$libdir/postgis-3','ST_AsGeoJsonRow'
 strk-#         LANGUAGE 'c' STABLE STRICT PARALLEL SAFE
 strk-#         COST 1;
 ERROR:  cannot change name of input parameter "pretty_print"
 HINT:  Use DROP FUNCTION st_asgeojson(record,text,integer,boolean) first.
 }}}

-- 
Ticket URL: <https://trac.osgeo.org/postgis/ticket/4483#comment:18>
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