<br><br><div><span class="gmail_quote">On 7/4/07, <b class="gmail_sendername">Brent Wood</b> <<a href="mailto:pcreso@pcreso.com">pcreso@pcreso.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>Hi Steve,<br><br>Hope this helps...<br><br>If I understand you correctly, this may be easier outside of PostGIS<br>geometries, try:<br><br>select geometryfromtext(('POINT( avg(longitude) avge(latitude) ',4326)
<br>group by ....<br><br>Always assuming the avg() is a appropriate value to use for your purposes.</blockquote><div><br><br>I guess I was under the idea that avg() functions don't quite work in geography for latitude and longitude. Is this not the case?
<br><br><br></div><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">If you didn't have the lat/long values outside a POINT geometry column, the
<br>same result would be achieved by:<br><br>select geometryfromtext(('POINT( avg(X(coords)) avg(Y(coords)) ',4326)<br>group by...<br><br><br><br><br> Cheers,<br><br>   Brent Wood<br><br><br>> UPDATE table SET coords =  geometryfromtext('POINT( longitude latitude )',
<br>> 4326)<br>><br>> ( 4326 is the projection value that I understand is useful in the United<br>> States.<br>><br>> So now that I have a bunch of lats, longs, and coordinates, I need to find<br>> the center point for any group of them. I can do a select query to get the
<br>> specific records I'm looking for, and then I can have the list of lat&long<br>> points, or the coordinate geometry. How then do I take those rows and create<br>> an SQL st<br>><br>><br>> UPDATE table SET coords = geometryfromtext(' MULTIPOINT( $lat1 $long1,
<br>> $lat2 $long2, $lat3 $long3)', 4326)<br>><br>> Can I use the 'coords' geometry object instead?<br>><br>><br>><br>> --<br>> "Computers are useless. They can only give you answers"
<br>> -- Pablo Picasso<br>> > _______________________________________________<br>> postgis-users mailing list<br>> <a href="mailto:postgis-users@postgis.refractions.net">postgis-users@postgis.refractions.net
</a><br>> <a href="http://postgis.refractions.net/mailman/listinfo/postgis-users">http://postgis.refractions.net/mailman/listinfo/postgis-users</a><br>><br><br></blockquote></div><br><br clear="all"><br>-- <br>"Computers are useless. They can only give you answers"
<br>-- Pablo Picasso