GeoNames Home
|
Postal Codes
|
Download / Webservice
|
About
GeoNames Forum
Search
Recent Topics
Back to home page
Register
/
Login
findNearbyPostalCodes webservice: unexpected result with maxRows=1
Forum Index
->
General
Author
Message
05/10/2006 17:59:34
Subject:
findNearbyPostalCodes webservice: unexpected result with maxRows=1
Anonymous
Hi,
While evaluating the results of the findNearbyPostalCodes webservice for locations in The Netherlands, I ran into the following issue:
I used the following queries:
http://ws.geonames.org/findNearbyPostalCodes?lat=51.55&lng=5.09&style=LONG
http://ws.geonames.org/findNearbyPostalCodes?lat=51.55&lng=5.09&style=LONG&maxRows=1
The result of the first query (without maxRows=1):
<geonames>
<code>
<postalcode>5009</postalcode>
<name>Tilburg</name>
<countryCode>NL</countryCode>
<lat>51.55</lat>
<lng>5.1166667</lng>
<adminCode1>NB</adminCode1>
<adminName1>Noord Brabant</adminName1>
<adminCode2/>
<adminName2>MIDDEN-NOORD-BRABANT</adminName2>
<distance>1.843766967748772</distance>
</code>
<code>
<postalcode>5008</postalcode>
<name>Tilburg</name>
<countryCode>NL</countryCode>
<lat>51.55</lat>
<lng>5.1166667</lng>
<adminCode1>NB</adminCode1>
<adminName1>Noord Brabant</adminName1>
<adminCode2/>
<adminName2>MIDDEN-NOORD-BRABANT</adminName2>
<distance>1.843766967748772</distance>
</code>
<code>
<postalcode>5007</postalcode>
<name>Tilburg</name>
<countryCode>NL</countryCode>
<lat>51.55</lat>
<lng>5.1166667</lng>
<adminCode1>NB</adminCode1>
<adminName1>Noord Brabant</adminName1>
<adminCode2/>
<adminName2>MIDDEN-NOORD-BRABANT</adminName2>
<distance>1.843766967748772</distance>
</code>
<code>
<postalcode>5049</postalcode>
<name>Tilburg</name>
<countryCode>NL</countryCode>
<lat>51.55</lat>
<lng>5.1166667</lng>
<adminCode1>NB</adminCode1>
<adminName1>Noord Brabant</adminName1>
<adminCode2/>
<adminName2>MIDDEN-NOORD-BRABANT</adminName2>
<distance>1.843766967748772</distance>
</code>
<code>
<postalcode>5056</postalcode>
<name>Berkel-Enschot</name>
<countryCode>NL</countryCode>
<lat>51.53000002</lat>
<lng>5.0866667</lng>
<adminCode1>NB</adminCode1>
<adminName1>Noord Brabant</adminName1>
<adminCode2/>
<adminName2>MIDDEN-NOORD-BRABANT</adminName2>
<distance>2.235705232137345</distance>
</code>
</geonames>
The results of the second query (with maxRows=1):
<geonames>
<code>
<postalcode>5056</postalcode>
<name>Berkel-Enschot</name>
<countryCode>NL</countryCode>
<lat>51.53000002</lat>
<lng>5.0866667</lng>
<adminCode1>NB</adminCode1>
<adminName1>Noord Brabant</adminName1>
<adminCode2/>
<adminName2>MIDDEN-NOORD-BRABANT</adminName2>
<distance>2.235705232137345</distance>
</code>
</geonames>
In my opinion, the second query should return the closest result, but as you see it doesn’t. Doesn’t that sort ascending on distance?
Regards,
Marco
05/10/2006 22:18:31
Subject:
Re:findNearbyPostalCodes webservice: unexpected result with maxRows=1
marc
Joined: 08/12/2005 07:39:47
Messages: 4416
Offline
Thanks Marco. This is was a bug and was fixed right now.
Regards,
Marc
06/10/2006 08:16:03
Subject:
Re:findNearbyPostalCodes webservice: unexpected result with maxRows=1
Anonymous
Hi Marc,
Thank you for your quick response!
Regards,
Marco
Forum Index
->
General
Go to:
Select a forum
Forum in English
-------------
General
Administrative Divisions
FAQ - frequently asked questions
Postal Codes
Discussion of GeoNames Toponyms
Forum in other language
-------------
Forum in Deutsch
Powered by
JForum 2.1.5
©
JForum Team
info@geonames.org
GeoNames Home
Postal Codes
Download / Webservice
Forum
About