[postgis-users] Should the spatial_ref_sys table be updated using the "ALTER EXTENSION...UPDATE" command?
McCoy, Shawn
shamccoy at amazon.com
Mon Nov 22 10:56:10 PST 2021
I looked through code and didn't see any update commands or any calls to "spatial_ref_sys.sql" in the script "postgis--ANY--3.1.4.sql". In 3.1.4 there are several new rows in the table.
1. Is this object purposely not recreated via the update script?
2. In the docs: https://postgis.net/docs/manual-3.0/postgis_installation.html#upgrading, is this why the "HARD UPGRADE" method is required? If so, why is there even a symlink named "postgis--2.4.5--3.1.4.sql"?
Thanks for any information,
Shawn
quick repro of my question:
postgres=> create extension postgis version '2.4.5';
CREATE EXTENSION
postgres=> select count(*) from spatial_ref_sys;
count
-------
5757
(1 row)
postgres=> alter extension postgis update to '3.1.4';
WARNING: unpackaging raster
WARNING: PostGIS Raster functionality has been unpackaged
HINT: type `SELECT postgis_extensions_upgrade();` to finish the upgrade. After upgrading, if you want to drop raster, run: DROP EXTENSION postgis_raster;
ALTER EXTENSION
postgres=> select count(*) from spatial_ref_sys;
count
-------
5757
(1 row)
whereas...
postgres=> create extension postgis version '3.1.4';
CREATE EXTENSION
postgres=> select count(*) from spatial_ref_sys;
count
-------
8500
(1 row)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20211122/a67e46cb/attachment.html>
More information about the postgis-users
mailing list