I am trying to return this query with the four nearest neighbours but cannot get the syntax right as im new to postgis. This should be simple for someone with experience with postgis. Would really appreciate help with this one.
var query3 = $.getJSON(('[login to view URL] * FROM "mapcomm-admin".permaculture_groups_gb_sct ORDER BY ST_Distance("mapcomm-admin".[login to view URL] <-> SRID=26918;POINT(583571.905921312 4506714.34119218) ::geometry)'));