BLOG | Download countries and codes table for MySQL

Share on:
Posted 19 May by David Bainbridge

Many applications require a MySQL table of all the countries in the world and their corresponding country codes, but compiling that manually would be a bit of a chore! 

You can view an up-to-date full list of the countries available and their associated codes on the ISO Online Browsing, but to save you some typing time see a MySQL database table export below:

MySQL database table

Countries.sql 6.1kb - Download

Importing

Copy the contents of the above file into the 'Contents' tab in phpMyAdmin, or use the 'Import' tab to upload the file directly. See 'next' link below for importing via command line. 

 

 

 

Share on:
Sign Up

NEXT: Locally set up mysql on command line for large sql imports

In this post we're going to look at setting up mysql on command line for a local machine (i.e. one using server software like WAMPSERVER or XAMPP), and then importing a large SQL file.

comments powered by Disqus
Sign Up

Popular Tags

350x250

Need a web developer?

If you'd like to work with code synthesis on your next project get in touch via the contact page.