June 16th, 2013, 12:49 PM
Google Latitude (to much decimals)
I'm using Google Geocoder to get lat/lng from location. Now the problem is the result sometimes has many more characters then normal..
-73.67942649999998 , I got this value from the variable.
The problem is I want to prepare my database but Float( 10,6 ) is not enough to hold this variable.
June 16th, 2013, 02:14 PM
I don't really understand the problem, if you want to store a more precise value then change your database structure, if you don't, then don't.
June 16th, 2013, 02:15 PM
I found the solution. The problem was that the lat/lng number had a different length every time. Sometimes 6 decimals, sometimes more
Originally Posted by E-Oreo
I always have the 6 decimals behind the comma.
latitude = results.geometry.location.lat().toFixed(6);