Re: earthdistance

From: Brent Wood <Brent(dot)Wood(at)niwa(dot)co(dot)nz>
To: Olivier Chaussavoine <olivier(dot)chaussavoine(at)gmail(dot)com>, "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: earthdistance
Date: 2013-08-10 00:18:37
Message-ID: B30242D206AB9543A3406649674DB41995803086@welwexmb01.niwa.local
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

You might install Postgis to implement very powerful spatial functionality that can easily do what you are asking (plus a whole lot more).
http://www.postgis.org

Now that v2 installs as a Postgres extension, it is more closely coupled with the underlying database.

Brent Wood

Programme leader: Environmental Information Delivery
NIWA
DDI: +64 (4) 3860529
________________________________________
From: pgsql-general-owner(at)postgresql(dot)org [pgsql-general-owner(at)postgresql(dot)org] on behalf of Olivier Chaussavoine [olivier(dot)chaussavoine(at)gmail(dot)com]
Sent: Saturday, August 10, 2013 7:29 AM
To: pgsql-general(at)postgresql(dot)org
Subject: [GENERAL] earthdistance

I develope a project openbarter that needs to match objects based on a maximum distance between their positions on earth. I saw that the documentation of the extension earthdistance was interesting, but the promise was not in the code. It would be nice to have these functions available independently of sophisticated geographic systems. There is a circle object for flat two dimensional space, but earth deals with spherical caps. It would not be exact but enough to suppose that earth is a sphere and that all dimensions latitude, longitude and distance are in radian.
What would need to be done to adapt the circle type to a new type 'spherical cap' that would allow simple geographic indexing?

--
Olivier Chaussavoine
--
Please consider the environment before printing this email.
NIWA is the trading name of the National Institute of Water & Atmospheric Research Ltd.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Uwe Schroeder 2013-08-10 05:50:36 Re: earthdistance
Previous Message Bruce Momjian 2013-08-09 23:26:42 Re: Type to to_char(d, 'J')?