gbif / geocode

Geocode webservice and client
Apache License 2.0
5 stars 4 forks source link

gadmGid filter doesn't work as expected #19

Closed MortenHofft closed 1 year ago

MortenHofft commented 1 year ago

Via by https://github.com/gbif/hp-land/issues/5#issuecomment-1424070648

It is possible to use the gadm API to restrict suggestions https://api.gbif.org/v1/geocode/gadm/search?limit=100&q=berlin includes berlin El Salvador

restricting that with a gadmGid=DEU https://api.gbif.org/v1/geocode/gadm/search?limit=100&q=berlin&gadmGid=DEU and we only get Berlin in Germany

But with q=Leipzig it doesn't work even though we have an entry for it https://api.gbif.org/v1/geocode/gadm/search?limit=100&q=Leipzig has results in Germany https://api.gbif.org/v1/geocode/gadm/search?gadmGid=DEU&limit=100&q=Leipzig no results

"id": "DEU.14.7_1",
"name": "Leipzig",
T-Engel commented 1 year ago

Thanks for raising this issue here. I'm just leaving a comment, so I get notified if there are any fixes for this bug. Fixing this would help us a lot :)