Opened 4 years ago
Closed 4 years ago
#4841 closed enhancement (fixed)
find_topology
Reported by: | strk | Owned by: | strk |
---|---|---|---|
Priority: | medium | Milestone: | PostGIS 3.2.0 |
Component: | topology | Version: | master |
Keywords: | Cc: |
Description
Not sure about which name to give to this function but I feel the need for a function that takes a reference to a Topology layer (table REGCLASS, column NAME) and returns the name of a topology (or a whole record for the topology, could be even better)
Currently proposed name was made after current find_srid
function, but suggestions for a better name are welcome.
Change History (7)
comment:1 by , 4 years ago
Milestone: | → PostGIS 3.2.0 |
---|
comment:2 by , 4 years ago
Seems fine and fine to return a topology record.
Only thing that might be an issue is if you delete a column on the topology table (which I assume would be rare), you'd have to drop this function first. I forget if adding a column has similar affect. Like with table types you need to do a CASCADE for dependent objects.
comment:3 by , 4 years ago
I did find a problem:
ERROR: cannot drop table topology because other objects depend on it DETAIL: function findtopology(topogeometry) depends on type topology
The uninstall script would need more love if we had to add similar functions
comment:4 by , 4 years ago
Merge request https://gitlab.com/postgis/postgis/-/merge_requests/17 tackles the above problem
comment:6 by , 4 years ago
WIP for FindTopology is in https://gitlab.com/nibioopensource/pgtopo_update_sql/-/merge_requests/54 Waiting for documentation before being merged :)
I'm thinking we'd want to accept the possible "query types":
Example usage: