Comments (6)
I guess it's not possible easily ?
It would be trivial to implement using something like PostGIS but difficult to implement with Elasticsearch.
It's been requested before but unfortunately I don't think we would consider adding it, we don't want to be offering general GIS query functionality better suited to a RDBMS.
from pelias.
Hi @stouch, postal codes are assigned to addresses, not localities.
In the case of Lille, it has many postcodes such as 59000, 59350, 59130 etc.
If you search for an address within Lille you will get the postcode if we have it, for instance:
https://pelias.github.io/compare/#/v1/place?ids=openaddresses%3Aaddress%3Afr%2Fcountrywide%3A3e9871c9baaee154
from pelias.
If you're interested in having a look at the postalcode coverage in France, we offer free downloads of the boundary data in Shapefile format which you can open in a desktop software GIS program such as QGIS:
https://geocode.earth/data/whosonfirst#FR
![Screenshot 2023-06-23 at 11 34 42](https://private-user-images.githubusercontent.com/738069/248232279-71898533-e20a-460c-aa8f-d0f7c7391ca9.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTgxMTM3MDksIm5iZiI6MTcxODExMzQwOSwicGF0aCI6Ii83MzgwNjkvMjQ4MjMyMjc5LTcxODk4NTMzLWUyMGEtNDYwYy1hYThmLWQwZjdjNzM5MWNhOS5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwNjExJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MDYxMVQxMzQzMjlaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT01MmY3Zjk3MzRmOTgyMTNhMWNjMmZkMjUwODNmMmQ2MzMxM2I2NDhiMDRlZTlhZTYwMjIzMTczZWI2ZTMyZDQ1JlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZhY3Rvcl9pZD0wJmtleV9pZD0wJnJlcG9faWQ9MCJ9.pJ94NbRIZUMd1zmR9joIlYCCQg_MvsF2CWovsgtivwc)
![Screenshot 2023-06-23 at 11 34 27](https://private-user-images.githubusercontent.com/738069/248232256-42dcc5e8-1c58-4cc8-90f0-e2bf7db87387.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTgxMTM3MDksIm5iZiI6MTcxODExMzQwOSwicGF0aCI6Ii83MzgwNjkvMjQ4MjMyMjU2LTQyZGNjNWU4LTFjNTgtNGNjOC05MGYwLWUyYmY3ZGI4NzM4Ny5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwNjExJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MDYxMVQxMzQzMjlaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT1lNDJmMzVjMTdlZDk0YTgxM2MyYjRiNjZhNDc3ZDY5NjQzMzZhZGE0MzUxMWZmZWNiMzBkZjAzNjViNDYwMTBkJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZhY3Rvcl9pZD0wJmtleV9pZD0wJnJlcG9faWQ9MCJ9.7DuLZ5CG7cKHKBM194z9NwITdN273C1rdMqMA8PENmM)
from pelias.
Hi @stouch, postal codes are assigned to addresses, not localities.
In the case of Lille, it has many postcodes such as 59000, 59350, 59130 etc.
If you search for an address within Lille you will get the postcode if we have it, for instance: https://pelias.github.io/compare/#/v1/place?ids=openaddresses%3Aaddress%3Afr%2Fcountrywide%3A3e9871c9baaee154
I'd love to get any trick to list all the postal codes of a locality, using only whosonfirst (and/or geonames) only.
I guess it's not possible easily ?
from pelias.
#887 #856 #111 GIScience/openrouteservice#1163
from pelias.
Hi there, sorry for the hijack, we did a special API some time ago for this special use case in France, Belgium, Italy and Switzerland. It was supposed to be a temporary solution until an integration in pelias.
GET https://api.jawg.io/postalcode/api/postalcode?city=lille&access-token=
[
{
"postalcode": "2275",
"country": "BE"
},
{
"postalcode": "59160",
"country": "FR"
},
{
"postalcode": "59000",
"country": "FR"
},
{
"postalcode": "59777",
"country": "FR"
},
{
"postalcode": "59260",
"country": "FR"
},
{
"postalcode": "59800",
"country": "FR"
}
]
The other solution, is by using two calls, one with search/autocomplete with your city and the second one a reverse geocoding (postalcode are available in reverse geocoding in Jawg APIs), this is the best solution IMO.
from pelias.
Related Issues (20)
- Update CI and Docker images to Ubuntu 22.04 HOT 4
- Difference between geocode.earth and local install of Pelias ? HOT 1
- Elasticsearch 8 support HOT 19
- Using Overture Maps for Data HOT 6
- Pelias Snapshot Update Date HOT 2
- Inconsistencies in response for the same query (when server overloaded)
- Transcription of German special characters in structured queries
- Venue, data source
- Error Postal Code
- Not able to setup pelias on my server
- While integrating custom WhosOnFirst data, old WOF-data is also available HOT 3
- Inaccurate Reverse Geocoding In Europe HOT 7
- Search for localities and counties of the same name HOT 5
- Additional parameters boundary.region and boundary.locality for autocomplete
- Neighborhood in the structured search worsens the results HOT 3
- Inaccuracies with the "Bangalore" location options. HOT 12
- Kyeongki-Do is outdated and should be Gyeonggi-do
- /search endpoint in my server returns multiple results for a given address , https://pelias.github.io/compare/ returns a single one result
- Administrative hierarchy data in pelias HOT 1
- Pelias does not return the address despite having it in index HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pelias.