Re: How long is a piece of string?
If it is degrees, then shouldn't this formula output 90?
--------
SET @pt1 = ASBINARY(GeomFromText('POINT(0 0)')), /** equator, meridian line */
@pt2 = ASBINARY(GeomFromText('POINT(90 90)')); /** north pole */
SELECT GLength(LineStringFromWKB(LineString(@pt1,@pt2))) AS distance;
--------
output
127.279
... which is equal to trig function SQRT(90^2 + 90^2), thats all this function is doing.
as expected this works
--------
SET @pt1 = ASBINARY(GeomFromText('POINT(0 0)')), /** equator, meridian line */
@pt2 = ASBINARY(GeomFromText('POINT(90 0)')); /** north pole */
SELECT GLength(LineStringFromWKB(LineString(@pt1,@pt2))) AS distance;
--------
output
90
How intolerable!
Subject
Views
Written By
Posted
4494
August 18, 2009 10:51AM
2920
August 18, 2009 12:37PM
Re: How long is a piece of string?
3343
August 18, 2009 01:48PM
5365
August 19, 2009 05:11AM
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.