NUMBER(8,5). You'll need around 5 digits after the decimal point. (Think GPS
accuracy == 10 meters for high-grade, 100 m for dumbed-down civilian use. At
the equator, that's 0.00009 or 0.0009 degrees respectively. At higher
latitudes, that'd be correspondingly less.)

If you value accuracy, DON'T USE FLOAT. Float has only 6-7 digits of
accuracy, which, if you take out the 3 digits before the ".", leave you with
only 3 decimal places after (== roughly 1 km - too rough).

Use Double (which would be 8 characters), or use number (8,5) or number
(7,4), which are approximately the same size. The latter are easier to work
with for display purposes, the former for computation purposes. Take your
pick.  If you use NUMBER(#,#), you should make sure that internally, you
convert them directly to and from double to preserve the accuracy of the
numbers. 

> -----Original Message-----
> From: Nelson Goforth [mailto:[EMAIL PROTECTED]]
> Sent: Monday, June 25, 2001 2:03 PM
> To: [EMAIL PROTECTED]
> Subject: Lat/Long storage?
> 
> 
> I need to store latitude and longitude in a MySQL table.  It needs to 
> allow human entry.  Do you have a preferred storage technique for 
> these numbers?
> 
> Nelson Goforth
> -- 
> 

Reply via email to