GeoNames Home | Postal Codes | Download / Webservice | About 

GeoNames Forum
  [Search] Search   [Recent Topics] Recent Topics   [Groups] Back to home page 
[Register] Register / 
[Login] Login 
Good autocompletion service needed  XML
Forum Index -> General Go to Page: Previous  1, 2
Author Message
sleidia



Joined: 19/01/2009 19:05:30
Messages: 12
Offline

terryh wrote:
...
I thought you were going to get the separate postal codes data and use that?
.... 


The separate postal codes aren't the one common people use here.
The postal codes we use are the ones stored in alternate_names which means that the column for postal codes become useless for France.

Anyway, thanks again for your help
terryh



Joined: 14/01/2009 13:54:55
Messages: 17
Offline

It's easy enough to extract just the postcode from the alternate_names field, for France.

It looks like the postcode always pre-ceeds any text and it's always 5 digits long.
There's a few ways you could extract the code easily.

Read off the first 5 chars from' alternate_name's and use a regular expression to match it against the postcode format. The regular expression is even given in the country_info data.
terryh



Joined: 14/01/2009 13:54:55
Messages: 17
Offline

What is the data in the admin4 field?
That looks like postcodes too, but not the same numbers as in the alternate names field.
sleidia



Joined: 19/01/2009 19:05:30
Messages: 12
Offline

After some research, the codes in admin4 are in fact INSEE codes.
The real postal codes that everyone use in their daily lives are stored in alternate_names.

For example, the postal code for Creteil is 94000 but admin4 is set to 94028 which is the INSEE code.

http://www.geneawiki.com/index.php/94028_-_Cr%C3%A9teil
http://www.lescommunes.com/commune-creteil-94028.en.html

MichaelDBang



Joined: 29/01/2009 05:45:05
Messages: 3
Offline

Is there a way that I can get the postal code regular expression from a web service call?
 
Forum Index -> General Go to Page: Previous  1, 2
Go to:   
Powered by JForum 2.1.5 © JForum Team