GeoNames Home | Postal Codes | Download / Webservice | About 

GeoNames Forum
  [Search] Search   [Recent Topics] Recent Topics   [Groups] Back to home page 
[Register] Register / 
[Login] Login 
unassigned Adm2code  XML
Forum Index -> Administrative Divisions
Author Message
david masclet



Joined: 26/11/2007 11:49:58
Messages: 67
Offline

During my dev on Gisgraphy i found several errors and try to correct them. i see that a lot of Adm2 that have no Adm2code assigned. Here is a summary to correct the errors for adm2code and adm1code that are not assigned.
i will do the one for adm3 a next time

for a country if there is no adm2 exported in ADM2code.txt and some adm2 for this country are in 'error'= >i say "all ko" that means that all need a code
for a country if there is some adm2 exported in ADM2code.txt and no adm2 for this country are in 'error'= >i say "all OK" that means that all need a code
for a country if there is no ADM2 exported in ADM2code.txt and no adm2 for this country are in 'error'= >i say "NO ADM2" that means that all need a code
for a country if there is some ADM2 exported in ADM2code.txt and some adm2 for this country are in 'error'= >i give the error at the end in # special errors# section


when a country is ALL OK or NO ADM2 (there is no adm2 for this country so they don' need to be updated) : nothing to do
when a country is ALL KO : all the ADM2 for this country need an adm2code . The strategy must be defined but as you told me maybe the feature id of the adm2 can be assigned). it could be great to run an sql command like this

Example for PL :
update geonames set adm2code = id where adm2code is null and country = pl;


DE: ALL OK
DK: ALL OK
ES: all adm2 are ok; 6362988;Melilla; is an adm1 without adm1code
IT : all OK
EH : 6547304;Oued Ed-Dahab-Lagouira is an ADM1 without ADM1code
FR: ALL OK
GB: ALL OK
GR: all adm2 should have a ADM2code; the rules seems to be a part of the ascii name in uppercase and 6692223;Pilion; is an adm1 without adm1code
GT : ALL KO
HN : ALL KO
HR : ALL KO
HT : ALL KO
JE : 6620384;Jersey (general) is an adm1 without adm1 code should be 0 i think because it is 'general'
ID : ALL KO
IN : ALL KO
IQ : ALL KO
IR : ALL KO
KP : all adm2code are missing execpt for feature id 1866790 1869039 1871865 1875980 1876380 1876403 2038910 2041726 2044803 but you can update all ADM2 for country KP because the ADM2 code is the name (not the ascii one. i wonder if it is a good choice)

KR : ALL KO
KZ : ALL KO
LA :ALL KO
LB : ALL KO
LC : no adm2
LK : ALL KO
LR : ALL KO
LS : no adm2
LT :ALL KO
LU : ALL ok
LY : 2208403;Mutuşarrifīyat Ghadāmis is the aonly ADM2 and need an adm2code to be assign : maybe 18 according http://fr.wikipedia.org/wiki/Libye
LV : NO ADM2
MC : No adm2
MD : all nok
MQ : all OK
MR : no adm2
MS : no adm2
MT : NO adm2
MU : no adm2
MV : no adm 2
MW : no adm2
MX : no adm2
MY : all nok
MZ all nok (only 2)
NA : no adm2
NC : all nok (3)
NE : all NOK
NF : NO
NG : ALL NOK
NI : ALL NOK
NL : ALL OK
NO : ALL ADM2 OK; 6620379;Bouvetøya (general) is an adm1 without adm1code
NP :ALL NOK
NR : NO ADM2
NU : NO ADM2
NZ : NO ADM2
OM : NO ADM2
PE : ALL NOK
PA : ALL NOK
PF : ALL NOK
PG : NO ADM2
PH : ALL NOK
PK : ALL NOK
PL : ALL NOK
PM : ALL OK
PN : NO ADM2
PR : NO ADM2
PS : NO ADM2
PT : ALL KO
PW : NO ADM2
PY : NO ADM2
QA : NO ADM2
RE : ALL OK
RO : ALL KO
RS : ALL KO
RU : some are missing but the code is the name (not ascii one so it can be batched)
RW : NO ADM2
SA : NO ADM2
SB : NO ADM2
SC : NO ADM2
SD : ALL KO
SE : ALL OK
SG : NO ADM2
SH : NO ADM2
SI : ALL KO
SJ : NO ADM2
SK : ALL KO
SL : ALL KO
SM : NO ADM2
SN : ALL KO
SO : ALL KO
SR : NO ADM2
ST : NO ADM2
SV : ALL KO
SY : ALL KO
SZ : NO ADM2
TC : NO ADM2
TD : NO ADM2
TF : ALL KO
TG : ALL KO
TH : ALL KO
TJ : ALL KO
TK : NO ADM2
TL : NO ADM2
TM : ALL KO
TN : ALL KO
TO : NO ADM2
TR : ALL KO
TT : ALL KO
TV : NO ADM2
TW : ALL KO
TZ : ALL KO
UA : ALL KO
UG : ALL KO
UM : NO ADM2
US : ALL OK
UY : NO ADM2
UZ : ALL KO
VA : NO ADM2
VC : NO ADM2
VE : ALL KO
VG : NO ADM2
VI : NO ADM2
VN : ALL KO
VU : NO ADM2
WF : ALL KO
WS : NO ADM2
YE : ALL KO
YT : NO ADM2
ZA : NO ADM2
ZM : ALL KO
ZW : ALL KO

Do you think it is a good idea to assign the featureId to the Adm2code for adm2 that are not assigned ?. an adm2 without adm2 code can not be referenced by features. i have done a first try and extract to a file . here is the result : http://gisgraphy.com/geonames/admin2Codes.txt
[WWW]
 
Forum Index -> Administrative Divisions
Go to:   
Powered by JForum 2.1.5 © JForum Team