vincentmorneau / oracle-geo-data

https://demo.insum.ca/ords/f?p=131
MIT License
22 stars 3 forks source link

Non-standard country codes #7

Closed skissane closed 7 years ago

skissane commented 7 years ago

It is not clear what the country codes are meant to be, but they look like ISO 3166-1 alpha2 codes.

But, given that interpretation, there are a few non-standard codes included:

insert into countries (country_id, code, name, phone_code) values (70, 'XA', 'External Territories of Australia', 61);
insert into countries (country_id, code, name, phone_code) values (91, 'XU', 'Guernsey and Alderney', 44);
insert into countries (country_id, code, name, phone_code) values (110, 'XJ', 'Jersey', 44);
insert into countries (country_id, code, name, phone_code) values (136, 'XM', 'Man (Isle of)', 44);
insert into countries (country_id, code, name, phone_code) values (199, 'XG', 'Smaller Territories of the UK', 44);

Now, for Isle of Man the standard code is IM not XM. For Jersey the standard code is JE is JE not XJ. For Guernsey the standard code is GG not XU. (And politically, Alderney is part of Guernsey.) So those entries should be changed to use the standard codes.

That then leaves us with XA and XG.

I have never seen anyone use "XA" to refer to the "External Territories of Australia". Australia has the following external territories: Ashmore and Cartier Islands - not listed, has no ISO 3166-1 standard code, nature reserve with no permanent inhabitants Australian Antarctic Territory - claim not recognised by many countries, included under AQ (Antarctica) Christmas Island - already in your list as code CX Cocos (Keeling) Islands - already in your list as CC Coral Sea Islands - not listed, has no ISO 3166-1 standard code, nature reserve with no permanent inhabitants Heard Island and McDonald Islands - already in your list as HM Norfolk Island - already in your list as NF

So, why have XA when all but two of Australia's external territories already have separate codes, and the two that lack them are uninhabited and hence irrelevant for most purposes?

The same comment applies to XG – all significant UK overseas dependencies already have entries, and those excluded have limited relevance (e.g. uninhabitated.)

So I would recommend deleting XA and XG on that basis.

vincentmorneau commented 7 years ago

Thank you for looking into this, especially that level of detail.

I am look into a major data enhancement for a future version.

vincentmorneau commented 7 years ago

I have checked these with the new (upcoming) data source and they are correct now.

"Coral Sea Islands" and "Ashmore and Cartier Islands" will not be part of the dump thought as there are no inhabitants. Including every inhabited zone would make the DB exponentially bigger. Feel free to add your areas when I publish v2.0.0.

vincentmorneau commented 7 years ago

fixed in https://github.com/vincentmorneau/oracle-countries-states-cities/commit/4ef3f9cfcf06d4cd27733da1a66e9ae9dbdc8baf