GeoNames Home | Postal Codes | Download / Webservice | About 

GeoNames Forum
  [Search] Search   [Recent Topics] Recent Topics   [Groups] Back to home page 
[Register] Register / 
[Login] Login doesn't work anymore!  XML
Forum Index -> General
Author Message

Joined: 24/06/2017 02:49:31
Messages: 2

Hello Geonames Database Master.

For several years now the following search URL has worked perfectly for me:

where q=0**** to q=9**** also worked as well returning a DECIMAL latitude/longitude coordinate pair. Which I used in my Python program with distance formula for any of you Pythonistas out there who may be interested for distances between two zip codes (decimal latitude / longitude coordinates)

Miles = Radius[0] * math.acos(math.sin(float(lat1)/57.29577951) * math.sin(float(lat2)/57.2957795) + math.cos(float(lat1)/57.29577951) * math.cos(float(lat2)/57.29577951) * math.cos(float(long2)/57.29577951 - float(long1)/57.29577951))

where Radius[0] = 3963 # 3437.74677 Nautical miles 6378.7 Kilometers

All joy, happiness and smiles until it didn't work anymore for all zip codes - depression, sadness and sorrow.

with a bleak, cryptic return of: No rows found for '14618'

On further examination I found this URL also worked/works

but returning only 0**** zip codes for little Rochester hamlets in New England.

Let's pick one Rochester, Vermont zip code 05767:

returning a nice: 43.88/-72.816 ... Beautiful!

But Aha!!, I found silver lining - a functional alternative!!!

works but returns: Latitude: N 43° 9' 17'' Longitude: W 77° 36' 56''

Yeah, yeah I know, I guess I could program my own degree-minute-second to decimal conversion or better yet find a plug-n-chug code snippet on the Internet but from my view/opinion the "original" is more elegant and I feel really meant or intended for my purposes and those similar in a "production sense" so to speak: DECIMAL latitude/longitude coordinates.

I was wondering if a fix could be instituted in the near future so I could refer back to it from the band-aid work-around I found.


Joel S.


Joined: 08/12/2005 07:39:47
Messages: 4139

Hi Joel

There was a bug in the postal code search. It has just been fixed. Sorry for the inconvenience.

Best Regards



Joined: 24/06/2017 02:49:31
Messages: 2


Thank you!! for your prompt attention to the issue I raised! Perhaps to the average guy on the street your webpage and services may not seem that important.

Ha! Quite the contrary! A lot of people like myself tune their apps to your webpage / services and a change in format or worse a cessation of your webpage would mean major reworks and finding other sources which would be in my opinion a daunting task.

For instance without getting into too many specifics (no pun intended) my SearchSpecifics app in Clinical Trial (CT) Mode matches clinical trials for me with my prostate cancer and when I release it in the near future free in the public domain (no strings) other people can use it likewise for their diseases and maladies.

Where comes in is generating a "ballpark - as the crow flies" mileage from my location to those of the clinical trials that post their location(s). Sometimes a given study/trial is being conducted concurrently in a few or more locations.

Anyway, I think you especially get the gist and a virtual tip of my hat and nod of appreciation directed your way! And no it was not too much of an inconvenience. Well done.


Joel S.
Forum Index -> General
Go to:   
Powered by JForum 2.1.5 © JForum Team