On Wed, 6 Jul 2022 09:41:00 +0200, Artur Krawczyk wrote:
> Therefore, let me divide the question into two parts.
> 1) First - Two topologies
> tplot - A large number of plots (or parcels) in some county, dozens
> or even hundreds of plots - a lot of nodes, borders and faces
> (existing objects)
> troad - the geometry of the road being designed (this is just a plan
> - but there is a precision geometry specified for this project for
> this county)
> I do not want to mix the geometry of the plots with the geometry of
> the designed road.
> I would like to use the function to intersect these two topologies
> between themselves.. Is it possible to perform such operations on
> these topologies?
absolutely NO. full stop.
a Topology is a self constrained Universe; comparing it in
any way with another different Topology has no sense at all.
"intersection" requires Geometries and not Topologies.
What you can do is:
1) transform both topologies into ordinary Geometry-based
tables (e.g. by calling TopoGeo_ToGeoTable)
2) then calling ST_Intersects() for indentifying all possible
intersection between the two "geom-tables" deriving from
the previous step.
> 2) Second "TopoGeo_FromGeoTable()"
> Sorry but only yesterday I read something about the
> "TopoGeo_FromGeoTable()" function and I do not fully understand the
> concept of how this function works.
> Using this function "TopoGeo_FromGeoTable()" can I turn geometry from
> "tplot" (node-border) into geometry - polygon (WKB)?
pay close attention, because you make some confusion between WKB
and native binaries geometries of SpatiaLite, that are a different
TopoGeo_FromGeoTable() works exactly in the opposti way;
it transforms a whole Geometry-Table into a corresponding
For transforming a Topology into a corresponding Geometry-Table
you should call instead TopoGeo_ToGeoTable().
> If so, further analysis I can use ST_Intersection function.
certainly yes: ST_Intersection() and ST_Intersects() are
the only two SQL functions intended for identifying any
possible intesection between geometries.
but they only accept Geometries and not Topologies.
said in different words:
a) a first conceptual model is the one based on OGC
Geometries (Points, Linestrings, Polygons etc)
b) a second conceptual model is the one based on ISO
Topologies, that implies a completely different
you can never mix the one with the other because they
are mutually not compatible.
what you can do is to transform Geometries into
Topologies or Topologies into Geometries, in such
a way as to correctly compare apples with apples
and oranges with oranges.