Re: getting access to geodistance (what do I need to install/enable) in an existing db install - Mailing list pgsql-general

From Michael Fuhr
Subject Re: getting access to geodistance (what do I need to install/enable) in an existing db install
Date
Msg-id 20060111225715.GA88522@winnie.fuhr.org
Whole thread Raw
In response to getting access to geodistance (what do I need to install/enable) in an existing db install  (Assad Jarrahian <jarraa@gmail.com>)
Responses Re: getting access to geodistance (what do I need to install/enable) in an existing db install  (Assad Jarrahian <jarraa@gmail.com>)
List pgsql-general
On Wed, Jan 11, 2006 at 02:40:04PM -0700, Assad Jarrahian wrote:
>   I was running postgres 8.1 on a windows xp box and I recall
> installing it with postgis option.
> I had a method in a db there that called geodistance. Everything worked fine.

Neither PostgreSQL nor PostGIS have a geodistance function, at least
not in recent versions.  However, PostGIS does have distance,
distance_sphere, and distance_spheroid functions.

> Now I tried to restore the db on the debian server thats running 8.1
> as well. The geodistance function (or any other geometry function ) is
> not available.

Googling for "geodistance" returns a few hundred hits, but googling
for "postgresql geodistance" or "postgis geodistance" yields only
a few hits.  The following message to pgsql-hackers from over five
years ago is the only hit I found in the PostgreSQL or PostGIS
mailing lists:

http://archives.postgresql.org/pgsql-hackers/2000-11/msg01232.php

I'd guess geodistance is or was part of some add-on.  If you connect
to the XP box with psql, what does "\df+ geodistance" show?  If
it's an SQL or PL/pgSQL function then you could copy its source
into the new database with CREATE FUNCTION, but maybe you'd be
better off using one of the standard functions.

What, if anything, does geodistance do that the standard PostGIS
distance functions don't?

--
Michael Fuhr

pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: Different exponent in error messages
Next
From: Assad Jarrahian
Date:
Subject: Re: getting access to geodistance (what do I need to install/enable) in an existing db install