1

What I am trying to do is the following:

  • I have an address XYZ
  • I have a list of other Addresses
  • I want to get out of the list, all the addresses within a certain distance of XYZ

Is it possible, if yes, which API would you recommend to do this? I would like to do this in a Java web-application that I am building using Spring.

I saw that with Google Places API, I would need to give the longitude and latitude of the place as well as the radius and a name of place I am looking for. Is this the common way to do this?

I can't do this with a list containing thousands of addresses since it would be too time consuming.

Would it be better to insert the longitude and latitude in the database at the time I am inserting an address (after verifying it with Google API and getting those information from there), then extracting the addresses within the proper radius directly in the SQL request?

I also found from this post: How to convert an address to a latitude/longitude?

That "use of the geocoder for any purpose other than obtaining locations that will be displayed using the Google Maps APIs is a violation of the Terms of Service."

So let's say that, if I build a website that will help people find "pizza places" near buy an address they input, then I display a list of these places on the website, it is illegal?

Community
  • 1
  • 1
dukable
  • 3,968
  • 11
  • 31
  • 42
  • you will somehow need the lat and long. then use the 'great_circle_distance' formula to see how far apart. – Randy Jul 09 '12 at 23:23
  • Have you taken a look at [Yahoo! PlaceFinder](http://developer.yahoo.com/geo/placefinder/)? Maybe the terms of use are more permissive... – Viccari Jul 09 '12 at 23:43
  • I found this about Yahoo! PlaceFinder on a forum: "We do not currently offer commercial terms of service for PlaceFinder. PlaceFinder is not intended to be used to populate a database with geocoding data, and geocoding results should be used within the same session during which they are generated." http://developer.yahoo.com/forum/PlaceFinder-General-Discussion/PlaceFinder-terms-of-use/1279742678000-8326e463-9607-3539-afa6-e9edca88e096 – dukable Jul 10 '12 at 00:22

0 Answers0