[postgis-users] deriving distance between lat/long points.

Brent Wood pcreso at pcreso.com
Tue Aug 16 19:42:01 PDT 2005


> Actually you can do this with a little bit of code and bypass PostGIS  
> (sorry list). Take a look at http://www.codeguru.com/Cpp/Cpp/ 
> algorithms/general/article.php/c5115/ for a good article on this topic.
> The code example is C++ but its pretty easy to distill down into  
> perl, python, etc. I've used this method in the
> past to write a small python script to do exactly what you want.  
> Unfortunately the script and the dodo bird now share
> the same fate.

Hi Gary, 

Thanks for that. Unfortunately (as Gavin has mentioned) my C/C++/Perl/Python is
about at a level also approached by the dodo bird, and has suffered a similat
fate :-) Shell scripts & SQL I can manage (or I thought I could until I tried
this!)

I'd like to get a PostGIS solution working, as I plan to run some workshops on
PostGIS/GMT/QGIS in the next month or two and this sort of use makes a good
example of what non-programmers can do. 

Hopefully someone can point out what I'm doing wrong with PostGIS, which will
be useful before the workshops as well :-)

FWIW, I do have a GMT equivalent using the v4 mapproject command, but so far
I'm failing miserably to complete an exercise I was going to use as a demo.


Cheers,

  Brent



More information about the postgis-users mailing list