Tag Info

Hot answers tagged

7

There's a good answer over at Stack Overflow, which goes a little something like this: The geography type is a little bit more restrictive than geometry. It can't cross different hemispheres and the outer ring must be drawn counter-clockwise. The rest can be found here. Another article goes into some more detail: If you’re looking for the ...


4

Maybe check out the properties of Projected Coordinate Systems, to get a view into their utility? There are 3 aspects or properties presented in Projected Coordinate Systems that establish their utility and rationale. Any projection of 3D space on a 2D surface will of course exhibit distortion versus reality. Depending on your application, using a specific ...


3

Your Line ... WHERE ST_geometrytype(geom) = ST_Point; Indicates that ST_Point is a column since it is not in quotes. I see here also a comment from @Vince that is saying basically the same thing that I am. Since ST_Point is not quoted in your expression is is trying to evaluate what is in ST_geometrytype(geom) against another field/column and it can't ...


3

If that code works you are creating a point on a sphere ( ::geography ) the buffering by a radius and requesting it as a shape on a plane ( ::geometry ) Then st_astext converts to wkt, yet more info (inc, any SRID) is returned via the PostGIS ST_AsEWKT calls. So you have some reading to do: Doc on geography and geometry ...


2

You can set the Output Coordinate System (Environment setting), but only certain tools will honor it. I don't think it will help for what you're doing. Why don't you just use coordinate pairs that are in the projected coordinate system you want to use? And then set the spatial reference when you create the polyline? arcpy.Polyline(inputs, ...


1

OpenLayers has a GetCentroid function for getting the centre of a polygon if you don't want to bring it in from the database directly: http://dev.openlayers.org/apidocs/files/OpenLayers/Geometry-js.html#OpenLayers.Geometry.getCentroid From there you should just be able to treat the point as a regular point feature. See also this example: ...


1

If you are particularly interested in using meters as the unit for the search, you can use geography data types instead of geometry types. All geography based calculations return values in meters. Also, ST_DWITHIN is designed for this type of queries: select * from zones z where ST_DWITHIN(Geography(ST_Transform(z.geom,4326)), ...



Only top voted, non community-wiki answers of a minimum length are eligible