MySQL Forums

Re: What returns from distance function?
Posted by: Mike McCutcheon
Date: May 03, 2010 06:51AM

Thanks Bjorn. That's an excellent link you gave us (eg cross-track error) but ...

I (and presumably Onur and others) would like to know what unit of measure the result of distance() uses. Only when I/we know that can we work out how to convert that result into km or miles.

I have been using distance() successfully for:
- working out whether point X is within polygon Y (distance = 0)
- comparing *relative* distances (point X is further from poly Y than point Z is)

But now I need to calculate *actual* distances so I obviously need to know what unit of measure is used.

My points, lines and polygons are plotted in Google Earth, so my guess is that the unit of measure of results from distance() between these places is degrees of latitude, so we multiply by 60 to get nautical miles etc. Is that right ?

Subject
Views
Written By
Posted
5004
April 18, 2010 06:01AM
4689
April 18, 2010 11:13AM
2861
April 28, 2010 08:58AM
Re: What returns from distance function?
3041
May 03, 2010 06:51AM
3891
May 07, 2010 01:35AM
2802
May 16, 2010 07:53PM
3025
May 17, 2010 02:52AM
3132
May 11, 2010 06:21PM
2488
July 08, 2010 01:42PM

Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.