3

I tried to solve a problem I had in QGIS (see Simplifying multiple lines to create central axis?).

I just need to know how the correct syntax works to use the function ST_ApproximateMedialAxis(geometry geom)

I successfully added the geometry to the pgAdmin4 Geometry Viewer with the query

select geom
from public.bufferrail

so that seems to be correct.

But how to include this geometry as argument to the function?

SELECT ST_ApproximateMedialAxis (select geom from public.bufferrail);

does not work. I tried several variations, with no success.

0

1 Answer 1

4

The correct query is:

SELECT
    uid,
    ST_ApproximateMedialAxis(geom)
FROM
    public.bufferrail;

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.