More info. Here are my 2 select statements.This one works:
$sth = $dbh->prepare("select ST_Asgeojson( geom ) from polys where
ST_Intersects(ST_GeomFromText('POLYGON(($textPoly, $closingLon $closingLat))',
4269), geom)=TRUE");
However, below is my new one, which I can't get to work:
$sth = $dbh
Hugues: Thanks for the info! I saw the link you posted a few days ago, but
was still having trouble making it work.The goal is to take what I have, which
uses the "ST_Intersects(ST_GeomFromText", and modify my existing query to use a
similar query with "ST_Intersects(ST_GeomFromGeoJSON" inste
Hello,
I'm not very familiar with the use of ST_GeomFromGeoJSON() but looking at the
doc, it only accepts a single json string so you'd better remove all the
ST_GeomFromText stuff: ST_GeomFromGeoJSON($jsonPolys). There are some examples
at the bottom of the page http://www.postgis.org/docs/ST_G