>From your initial approach, the following should work. I don't use
spheroid projections, so this was only tested with st_distance. I fudged
in the distance_spheroid. You may also want to replace the st_centroid
function with your field "geometry_centroid".
select max(myDistance) FROM
(
SELE
Try moving your query into a subquery and then taking the max distance. Also, you can probably drop the subquery you
put as a parameter to the generate_series call. Why are you converting the geometry to text, then back to a geometry again?
ie.
SELECT "cellID", max(dist)
FROM (
-- Your query
Behalf Of Obe,
Regina
Sent: Thursday, February 19, 2009 10:29 AM
To: PostGIS Users Discussion
Subject: RE: [postgis-users] Re: maximum distance between a POINT and
POLYGON
It hasn't been implemented. Well it was a long long time ago, but the
logic was incorrect so it was turned off.
We pl
-boun...@postgis.refractions.net] On Behalf Of
nicklas.a...@jordogskog.no
Sent: Thursday, February 19, 2009 8:50 AM
To: PostGIS Users Discussion
Subject: Re: [postgis-users] Re: maximum distance between a POINT and
POLYGON
Hallo
What is the problem with ST_Max_Distance(geometry g1, geometry g2)?
/Ni
Sorry, I guessST_Max_Distance(geometry g1, geometry g2) is just for linestrings
in current release
but in the doc for 1.4 it is presented with geometry1 and geometry2
/Nicklas
2009-02-19 My Pid wrote:
Hello again,
>
>I found the generate_series function (yes i am a newbie!) and I can use it in
Hallo
What is the problem withST_Max_Distance(geometry g1, geometry g2)?
/Nicklas
2009-02-19 My Pid wrote:
Hello again,
>
>I found the generate_series function (yes i am a newbie!) and I can use it in
>order to calculate the distance between
> my centroid (geometry_centroid) and my polygon