I have asked about exporting geometry as a table (Link) and I got a very nice answer about how to do it with an SQL instruction.
Is there a way to select only the inerior of line type data? i.e. only the vertex that are not the ends.
The following instruction will produce all vertex
SELECT sub.name AS "Pipe",
ST_X(sub.geom) AS "X-Coord",
ST_Y(sub.geom) AS "Y-Coord"
FROM (
SELECT name,
(ST_DumpPoints(geom)).geom AS geom
FROM conduits
) AS sub
Here is the output:
'1570','4978.95','2421.05'
'1570','2494.74','2421.05'
'1600','2494.74','2421.05'
'1600','2494.74','7536.84'
'1602','4957.89','7536.84'
'1602','2494.74','7536.84'
'8040','8115.79','3450.84'
'8040','9107.73','4350.80'
'8040','7463.16','7536.84'
I would like to get only:
'8040','9107.73','4350.80'