On Thu, Oct 19, 2006 at 09:31:40PM +0530, Sandeep Kumar Jakkaraju wrote: > I use postgis to wipe my ASS ... > no good documentation ... If you find the documentation lacking then please consider posting to postgis-users with suggestions for improving it. Even better, submit a patch :-) > in what units is the result of distance(geometry,geometry).. http://postgis.refractions.net/docs/ch06.html#id2526205 "Return the cartesian distance between two geometries in projected units." If the geometries are in degrees then distance() returns degrees; if they're in meters then distance() returns meters; if they're in cubits then distance() returns cubits. > what is distance_sphere(geometry,geometry).. http://postgis.refractions.net/docs/ch06.html#id2528534 "Returns linear distance in meters between two lat/lon points." > when u give same geometry as both parameters it gives a non-zero > value .... test=> SELECT distance(GeomFromText('POINT(12 34)'), GeomFromText('POINT(12 34)')); distance ---------- 0 (1 row) test=> SELECT distance_sphere(GeomFromText('POINT(12 34)'), GeomFromText('POINT(12 34)')); distance_sphere ----------------- 0 (1 row) If you're getting unexpected behavior then please post a test case to postgis-users. -- Michael Fuhr