GeoNames Home | Postal Codes | Download / Webservice | About 

GeoNames Forum
  [Search] Search   [Recent Topics] Recent Topics   [Groups] Back to home page 
[Register] Register / 
[Login] Login 
Lack of résult in children  XML
Forum Index -> Administrative Divisions
Author Message
navimap



Joined: 28/05/2007 19:09:14
Messages: 13
Offline

When I try
For example 'Aïn Sefra the hearchy return Willaya of Mostaganem for ADM1

http://ws.geonames.org/hierarchy?geonameId=2507942
<fcl>H</fcl>
<fcode>STM</fcode>

When I try to have the children of this Administration
http://ws.geonames.org/children?geonameId=2487130 there is no 'Aïn Sefra
but only <fcl>P</fcl>
<fcode>PPL</fcode>

Why not display all the fcode and fcl
[WWW]
marc



Joined: 08/12/2005 07:39:47
Messages: 4412
Offline

The children service returns administrative divisions till the last level and when there are no more administrative divisions it returns the cities.
Returning all features would return tens of thousands of rows and would no longer be managable.

Marc

[WWW]
navimap



Joined: 28/05/2007 19:09:14
Messages: 13
Offline

So it's possible with
http://ws.geonames.org/search?q=''&type=json&style=FULL&country='US'&adminCode1='NY'&fclass=A&fcode=ADM1

with 1000 rows maximum
[WWW]
marc



Joined: 08/12/2005 07:39:47
Messages: 4412
Offline

Yes, this is exactly what the children web service is doing. It first tries to find lower level admin divisions and if it has reached the bottom it searches for populated places. You can write your own children service without this restriction and get lakes or mountains or whatever you like.

Marc

[WWW]
navimap



Joined: 28/05/2007 19:09:14
Messages: 13
Offline

I found.

I add &style=full
--> http://ws.geonames.org/hierarchy?geonameId=2507942&style=full
It s very good site.
Thanks

[WWW]
 
Forum Index -> Administrative Divisions
Go to:   
Powered by JForum 2.1.5 © JForum Team