Skip to content
This repository has been archived by the owner on Jul 24, 2021. It is now read-only.

Searching by CA (canadian) / GB postcode #2830

Closed
openstreetmap-trac opened this issue Jul 23, 2021 · 6 comments
Closed

Searching by CA (canadian) / GB postcode #2830

openstreetmap-trac opened this issue Jul 23, 2021 · 6 comments

Comments

@openstreetmap-trac
Copy link

Reporter: jwhelan0112[at]gmail.com
[Submitted to the original trac issue database at 2.50pm, Thursday, 25th March 2010]

For GB postcodes either a search of "en3 6rg,gb" or "en36rg,gb" works fine.

For CA "k4a 1m7,ca" does not work, "k1e3p6,ca" does. Unfortunately k1e3p6 was entered in the wrong format. It should have been "ANA NAN" not "ANANAN" note the space.

Could the search code for GB be copied when searching for Canadian postcodes please. This would make OSM in Canada much more useful. Currently it is not possible to search Canada by postcode.

John

@openstreetmap-trac
Copy link
Author

Author: twain
[Added to the original trac issue at 4.16pm, Friday, 26th March 2010]

For GB postcodes either a search of "en3 6rg,gb" or "en36rg,gb" works fine.
The current GB version only works through a hideous hack which can't easily be extended because it uses a separate table of postcodes and knowledge of how the uk postcode system works to guess them.

For CA "k4a 1m7,ca" does not work, "k1e3p6,ca" does. Unfortunately k1e3p6 was entered in the wrong format. It should have been "ANA NAN" not "ANANAN" note the space.

I'm currently working on space sensitivity issue for the next version but this is unlikely to be fixed quickly.

--
Brian

@openstreetmap-trac
Copy link
Author

Author: jwhelan0112[at]gmail.com
[Added to the original trac issue at 4.34pm, Friday, 26th March 2010]

So for the moment if they are entered as ANANAN that should work fine and if ever it is sorted out some one can write a script to rundown the database and split it to the correct format.

Thanks John

@openstreetmap-trac
Copy link
Author

Author: jwhelan0112[at]gmail.com
[Added to the original trac issue at 1.16am, Sunday, 28th March 2010]

Idle thought time from my time with databases.

Could we have a hidden field for all postcodes that condensed any spaces. Then simply parse out any spaces in the search request and search against this when searching for postcodes.

Thanks

Cheerio John

@openstreetmap-trac
Copy link
Author

Author: twain
[Added to the original trac issue at 12.14pm, Monday, 29th March 2010]

They will currently work if entered exactly as entered in OSM - so if they are entered as "k4a 1m7" then they will be searchable as "k4a 1m7". I see you have updated the node in OSM - so this would be fixed except Nominatim is not currently being updated due to a database problem.

In general you should enter data correctly in OSM and wait for the tools to be improved.

A condensed index will be added to v2 of the code but due to the size of the data re-indexing is not trivial so it will not be changed instantly.

@openstreetmap-trac
Copy link
Author

Author: jwhelan0112[at]gmail.com
[Added to the original trac issue at 2.22pm, Monday, 29th March 2010]

"528, Merkley Drive, K4A 1N5,CA" gives the result "528, Merkley Drive, K1E3P6, Ontario, Canada" but does find the correct location. "K1E3P6" is an adjacent post code that was entered incorrectly.

528 is one of the early ones entered and it shows up as "K4A 1N5" in JOSM.

"K4A 1N5,CA" gives no results found as does
"578 Merkley Drive, Orleans, K4A 1M7,CA" The post codes are in upper case exactly as Canada Post directs they should be. We don't have issues with Canada Post saying you can't use our postcodes here. I spent a number of years looking into addresses and working with Canada Post on these issues.

A complicating factor would seem to be that although we have imported a large number of roads no city information was added. That is a separate issue that can be addressed. Looking in JOSM everything looks like it is in Ontario but even searches with Ontario bring up nothing.

I realise that Canada is far away from Europe but whilst it is a problem that affects Canadians most I am disappointed that we rate only a minor enhancement for something that doesn't appear to work.

@openstreetmap-trac
Copy link
Author

Author: lonvia
[Added to the original trac issue at 9.52am, Sunday, 11th May 2014]

Issue with wrongly displayed postcode has been fixed. Other postcodes work if they have been mapped in OSM and with the known limitation that postcode centroids are currently not updated.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant