My test scenario is to confirm the image below, I select the points on the line in order of the direction the line was drawn.
I used the sql:
Select testepoint."id" FROM testepoint inner JOIN teste ON ST_DWithin(teste.geom, testepoint.geom, 1) WHERE teste."id"= 1 ORDER BY ST_Line_Locate_Point(teste.geom, testepoint.geom)
I placed the order by to sort the way I want, as the line was drawn
ORDER BY ST_Line_Locate_Point(teste.geom, testepoint.geom)
And the error occurs:
ERROR: line_locate_point: 1st arg is not a line
This was because my geometry is a MultiLineString. How can I do this sort of which is a MultiLineString?