0

I have the path data labeled tabel_roads, I want to find the nearest road using coordinates. this is the script I have, but it does not work.

                            select id from tabel_roads ORDER BY geom <-> st_makepoint(-6.1688009873927925,106.8256151676178) LIMIT 1
2
  • please give me link :) Jun 4, 2018 at 3:26
  • btw., in ST_MakePoint, x is longitude, y is latitude - switch the ordinates!
    – geozelot
    Jun 6, 2018 at 8:40

0

Browse other questions tagged or ask your own question.