Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 3 years ago.
Improve this question
I want to make service with API that give some info about a city (in any country) by some id.
What I should choose as id for cities? Does there exist an ISO standard for city identification? If so, where I can get a list of city ids?
There is an ISO standard for Country code, but none (that I can find) for city code. There is, however;
a
United Nations Economic Commission for Europe
United Nations Code for Trade and Transport Locations system of city identification UN/LOCODE.
Edit: Lined out the wrong name, added the slash to the UN/LOCODE name.
I decided to use IATA codes for cities.
In addition to UNLOCODE, there is also the GeoNames database with its own numeric IDs.
This is probably only better than UNLOCODES if you already need to use the information in the GeoNames database or would prefer an integer-based ID system.
For Europe there are also the NUTS codes. It goes into different levels of detail, depending on the country. For some countries like Germany you get the code for cities while for other countries like Spain you get only regions.
Germany's example:
https://en.wikipedia.org/wiki/NUTS_of_Germany#Local_administrative_units
You can find the link to each country here:
https://en.wikipedia.org/wiki/Category:Nomenclature_of_Territorial_Units_for_Statistics
You may use ISO 3166-2 standarts:
http://en.wikipedia.org/wiki/ISO_3166-2
Related
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 8 years ago.
Improve this question
We've got a requirement in a couple of our systems to detect a user's country based on their IP address. We'd prefer to use a database rather than a Web Service (to prevent issues with downtime/network access to an externally hosted service) so I'm looking for recommendations, anyone got any good or bad stories of the various IP to Country databases?
What I've found from google:
Paid
Maxmind - $50, then $12 a month, site license
IP2Location - $50 a year, single server
software77 (Donationware)
Free
Maxmind Geolite
ip2nation
Any information on how the free ones compare to the paid ones would be good. Right now I'm leaning towards Maxmind's paid service since it includes automatic updates that we can run via script once a week.
Totally free, LGPL, not easily found in google: ip2c.org
We use Maxmind and it's very good, and pretty accurate. You can get scenarios where, say, a German company has offices in the US but is using a German IP range for internal purposes. So, they'll report as Germany while being based in the US. It won't be 100% reliable.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 6 years ago.
Improve this question
I currently use the Google Translate API (v2) to translate content from US English into various other languages that we support in our software. We then have a process whereby users can submit translation corrections so that we end-up with fairly well-done translations.
We would like to now add support for UK English so that our English-speaking software users in the UK may have a better user experience.
Is there any way to automate the conversion between US English and UK English, or do we just have to manually fix everything?
Don't know of anything automatic. But you could try to identify the most common differences and then search for them.
There is a list here:
http://en.wikipedia.org/wiki/American_and_British_English_spelling_differences
This would at least help with the manual effort.
Here are two tools I have found to do this:
http://www.us2uk.eu/ (dead website)
http://www.infoenglish.net/american-to-british-english/
I haven't tried these on large text blocks, however.
There's another tool which is available:
https://codewordsolver.com/american-british-english-translator (online)
https://github.com/hyperreality/American-British-English-Translator (source code)
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 5 years ago.
Improve this question
I found a lot of threads explaining how to get the country-codes in two- or three-letter format, but nothing that fits to my task.
I'm heading for a way to get all the top level domains in an array or something. I know there's the CultureInfo class in C# but which could list the country codes. It doesn't include generic TLD, e.g.: "com". Here's the complete list of country codes I found.
The authoritative list of all TLDs: http://www.iana.org/domains/root/db
The Root Zone Database represents the delegation details of top-level domains, including gTLDs such as .com, and country-code TLDs such as .uk.
You can get this as TXT, too (easier to parse): http://data.iana.org/TLD/tlds-alpha-by-domain.txt
Wikipedia also lists all TLDs, but it's not authoritative, of course: List of Internet top-level domains
The Mozilla Foundation maintains a Public Suffix List for effective top-level domains, i.e., those under which you can directly register names (for example .co.uk instead of .uk): http://publicsuffix.org/
I like to use this list (it includes private TLDs): http://mxr.mozilla.org/mozilla-central/source/netwerk/dns/effective_tld_names.dat?raw=1. To me it's the most complete list I could find and it's in a plain text format.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 4 years ago.
Improve this question
What I am looking to do is retrieving city statistics. Much like the CIA World Factbook. But, I want an API, database or dataset that I can query and get results. Also, I would actually PREFER to use a UIWebView and load a website with those statistics already searched and displayed. Like TheWeatherChannel for instance, I can form a URL with given coordinates. But websites like the CIA World Factbook have a unique two letter code for each country, which are not in a particular format.
Also, I would like to get CITY statistics, this would include:
Population
Crime Rate
Description
Languages Spoken
Transport Systems
Geography
and more! I even had an idea to show the type of plugs that country uses. But, I have no idea how and where to look for information like this.
Please help me out...
You're asking for very generic data sets and APIs, so you may want to being exploring http://en.wikipedia.org/wiki/Open_data, https://explore.data.gov/, and http://www.freebase.com/
A little late and it probably doesn't do city level but
http://data.worldbank.org/developers/data-catalog-api
could also be useful for someone looking for similar stuff and it wasn't mentioned (AFAICS) in the above answer's links.
This data also has a drupal module at
https://drupal.org/project/wbapi
Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 9 years ago.
Improve this question
In the world of internationalization, CLDR (Common Locale Data Repository) seems to be the ultimate database and as I learned, many systems derive their locale data from that.
However, I compared CLDR data and the locales in Windows 7 and currency formatting is different in many cases.
For example, Canadian dollar in locale "English (Canada)" is formatted as follows:
Windows: $1,235.00, -$1,235.00
CLDR...: $1,235.00, ($1,235.00)
Or let's take Spanish (Colombia) and Colombian peso:
Windows: $ 1.235,00, ($ 1.235,00)
CLDR...: $1.235,00, -$1.235,00
Note variations in negative numbers and spacing. What should I think of this? Most likely there are more such differences. Are both formatting rules OK, or could it happen that one is perceived by local users as wrong?
Although it is not programming related, I will try to answer your question.
I once asked on CLDR's internal mailing list about (incorrect) Polish date formats and suggested changes to it providing legal (Polish Standard) reference. The answer was that CLDR tries to follow national standards, but sometimes it might be a good idea to use commonly used format instead.
There are two answers to your question:
either the format defined is more commonly used than the one specified by the national standard
or simply there is an error in the definition - browse CLDR's bug tracking system, maybe there is (or was) something about it
As for Microsoft, I believe they are trying to follow national regulations and standards.