Skip to content
Advertisement

How would I go about populating an SQL database with world languages? [closed]

A PHP program that I’m working on requires a list of world languages. Preferably the list should contain the English name of the language and a unique, two-letter designation for each language. What would be the easiest way to create a table that contained that kind of data?

Advertisement

Answer

ISO 639 is a standards set for cataloging languages. ISO 639-1 in particular is made up of “Alpha-2 codes”, two-letter codes for 184 major languages. The following is an SQL query that can be used to create and populate a languages table with an Alpha-2 code accompanied by the English, German, French, and Spanish name of each language, using some of the data from the Library of Congress:

User contributions licensed under: CC BY-SA
8 People found this is helpful
Advertisement