[PostGIS] #5983: Data corruption in topology.topoelement and topology.topogeometry after upgrade to 3.6.0
PostGIS
trac at osgeo.org
Wed Oct 29 22:33:55 PDT 2025
#5983: Data corruption in topology.topoelement and topology.topogeometry after
upgrade to 3.6.0
-----------------------+---------------------------
Reporter: packi | Owner: robe
Type: defect | Status: new
Priority: blocker | Milestone: PostGIS 3.6.1
Component: topology | Version: 3.6.x
Resolution: | Keywords:
-----------------------+---------------------------
Comment (by strk):
Replying to [comment:23 robe]:
> Wouldn't you end up overupdating with that. I was thinking more like
>
> WHERE ( (topogeom).id & 0xFFFFFFFF ) <> (topogeom).id;
I was thinking more like:
{{{
WHERE ( xmin < ( select xmin from pg_proc where oid =
'topology.st_createtopogeo'::regproc )
}}}
Example state I've produced by sourcing the
topology/test/load_topology.sql and topology/test/load_features.sql while
in 3.5.5dev, upgrading to 3.7.0dev and then sourcing
topology/test/more_features.sql:
{{{
strk at strk=# select xmin,feature_name,geometrytype(feature) from
features.city_streets;
xmin | feature_name | geometrytype
-------+--------------+-----------------
37032 | R1 | UNEXPECTED
37032 | R2 | UNEXPECTED
37032 | R3 | UNEXPECTED
37032 | R4 | UNEXPECTED
37176 | E7E8 | MULTILINESTRING
37177 | E20E19 | MULTILINESTRING
37178 | E25 | MULTILINESTRING
37179 | R1a | MULTILINESTRING
(8 rows)
strk at strk=# select xmin from pg_proc where oid =
'topology.st_createtopogeo'::regproc;
xmin
-------
37035
(1 row)
}}}
For the function we'd better include a version name in the function, maybe
call it 'fix_topogeometry_column_currupted_by_3.6.0_upgrade` ?
--
Ticket URL: <https://trac.osgeo.org/postgis/ticket/5983#comment:25>
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