Database
World Cities Database
World Major Cities Database
Add-On
Web Service
World Cities Database Platinum Edition
Database of worldwide cities in text format suitable for any applications requiring a comprehensive list of cities name, state/province (ADM1), latitude, longitude, country code, population. It is a subset of the GeoDataSource™ Cities Database Titanium Edition.
Latest release: November, 2024
Click here to view breakdowns by country
Download Sample (173.11 kB)
- Free and Updated Monthly
- Multiple Subscriptions Packages Available
- Most Accurate and Up-to-Date Source of Data
- Comprehensive List of Cities and Related Items (3,766,259 Entries)
- Support Worldwide 260+ Countries, Territories and Sovereign Lands
- Instant Download Upon Subscription
- Free Customer Support
- Many Happy Customers
- Internet connection capable of downloading 90.31 MB compressed ZIP data file
- 90.31 MB free disk space for compressed file
- 361.23 MB free disk space for uncompressed data files
- WinZIP or other similar archive extraction utility
- SQL Server, Oracle, MySQL, PostgreSQL or other database software application capable of importing 3,766,259 records from a standard tab-delimited ASCII text file and sufficient disk space to import the database
Code | Feature Name | Description |
---|---|---|
PPL | Populated place | A city, town, village, or other agglomeration of buildings where people live and work. |
PPLA | Seat of a first-order administrative division | Seat of a first-order administrative division. |
PPLC | Capital of a political entity | Capital of a political entity. |
PPLL | Populated locality | An area similar to a locality but with a small group of dwellings or other buildings. |
PPLQ | Abandoned populated place | Abandoned populated place. |
PPLR | Religious populated place | A populated place whose population is largely engaged in religious occupations. |
PPLS | Populated places | Cities, towns, villages, or other agglomerations of buildings where people live and work. |
PPLW | Destroyed populated place | A village, town or city destroyed by a natural disaster, or by war. |
PPLX | Section of populated place | Section of populated place. |
PPLA2 | Second-order administrative division | Seat of a second-order administrative division. |
PPLA3 | Third-order administrative division | Seat of a third-order administrative division. |
PPLA4 | Fourth-order administrative division | Seat of a fourth-order administrative division. |
Field Name | Description | Type | Length |
---|---|---|---|
continent_id |
Continent ID. An id that determines the character mapping used in the full name field.
|
number | 1 |
sub_continent_id |
Sub-Continent ID. A sub division of continent id.
|
character | 2 |
ufi | Unique Feature Identifier. A number which uniquely identifies the feature. A feature with multiple names with share a same feature identifier. | number | 10 |
uni | Unique Name Identifier. A number which uniquely identifies a name. | number | 10 |
dsg | Feature Designation Code. A two to five-character code used to identify the type of feature a name is applied to. | character | 5 |
cc_fips | FIPS 10-4 Primary Country Code. A two alphabetic character FIPS 10-4 Primary Country Code uniquely identifying a geopolitical entity (countries, dependencies, and areas of special sovereignty). | character | 2 |
cc_iso | ISO 3166 Primary Country Code. A two alphabetic character ISO 3166 Primary Country Code uniquely identifying a geopolitical entity (countries, dependencies, and areas of special sovereignty). | character | 5 |
full_name | Feature's Full Name. The full name is a complete city name which identifies the named feature. It is comprised of the specific name, generic name, and any articles or prepositions. | character | 200 |
full_name_nd | Feature's No Diacritics Full Name. Same as the full name but the diacritics and special characters are substituted with Roman characters. | character | 200 |
sort_name | Feature's Sort Name. A form of the full name which allows for easy sorting of the name into alpha-numeric sequence. It is comprised of the specific name, generic name, and any articles or prepositions. This field is all upper case with spaces, diacritics, and hyphens removed and numbers are substituted with lower case alphabetic characters. | character | 200 |
adm1_code | First-Order Administrative Division Code. A two to three alphanumeric character code uniquely identifying a primary administrative division of a country, such as a state in the United States. | character | 3 |
adm1_full_name | First-Order Administrative Division's Full Name. The full name is a complete region name which identifies the first-order administrative division. It is comprised of the specific name, generic name, and any articles or prepositions. It is compliant with ISO 3166-2 for all countries except for the countries listed below,
Anguilla, Antarctica, American Samoa, Aruba, Aland Islands, Saint Barthelemy, Bermuda, Bahamas, Bouvet Island, Cocos (Keeling) Islands, Cook Islands, Curacao, Christmas Island, Western Sahara, Falkland Islands (Malvinas), Faroe Islands, French Guiana, Guernsey, Gibraltar, Guadeloupe, Heard Island and Mcdonald Islands, South Georgia and The South Sandwich Islands, Guam, Hong Kong, Isle of Man, British Indian Ocean Territory, Jersey, Cayman Islands, Saint Martin (French Part), Macao, Northern Mariana Islands, Martinique, Montserrat, New Caledonia, Norfolk Island, Niue, French Polynesia, Saint Pierre and Miquelon, Pitcairn, Puerto Rico, Reunion, Singapore, Svalbard and Jan Mayen, Sint Maarten (Dutch Part), Turks and Caicos Islands, French Southern Territories, Tokelau, Holy See, Virgin Islands, British, Virgin Islands, U.S., Mayotte |
character | 200 |
adm2_code | Second-Order Administrative Division Code. The name of a subdivision of a second-order administrative division, or known as a county in the United States. (US only). | character | 3 |
adm2_full_name | Second-Order Administrative Division's Full Name. The full name is a complete name which identifies the second-order administrative division. It is comprised of the specific name, generic name, and any articles or prepositions. (US only) | character | 200 |
latitude | Latitude in Decimal Degree. Latitude of the feature in ± decimal degrees (WGS84). no sign (+) = North; negative sign (-) = South. |
float | 10 |
longitude | Longitude in Decimal Degree. Longitude of the feature in ± decimal degrees (WGS84). no sign (+) = East; negative sign (-) = West. |
float | 10 |
population | City Population. Total number of human population by estimation in the top 12,000 cities in the world. | number | 10 |
-- Create table "world_cities_platinum"
CREATE TABLE `world_cities_platinum`(
`continent_id` INT,
`sub_continent_id` VARCHAR(2),
`ufi` INT,
`uni` INT,
`dsg` CHAR(5),
`cc_fips` VARCHAR(2),
`cc_iso` VARCHAR(2),
`full_name` VARCHAR(200),
`full_name_nd` VARCHAR(200),
`sort_name` VARCHAR(200),
`adm1_code` VARCHAR(3),
`adm1_full_name` VARCHAR(200),
`adm2_code` VARCHAR(3),
`adm2_full_name` VARCHAR(200),
`latitude` FLOAT,
`longitude` FLOAT,
`population` INT,
INDEX `idx_continent_id` (`continent_id`),
INDEX `idx_sub_continent_id` (`sub_continent_id`),
INDEX `idx_region` (`continent_id`,`sub_continent_id`),
INDEX `idx_cc_iso` (`cc_iso`),
INDEX `idx_dsg` (`dsg`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
-- Load data into table
LOAD DATA LOCAL
INFILE 'GEODATASOURCE-CITIES-PLATINUM.TXT'
INTO TABLE `world_cities_platinum`
FIELDS TERMINATED BY '\t'
LINES TERMINATED BY '\r\n'
IGNORE 1 LINES;
-- Create table "country"
CREATE TABLE `country`(
`cc_fips` VARCHAR(2),
`cc_iso` VARCHAR(2),
`tld` VARCHAR(3),
`country_name` VARCHAR(100),
INDEX `idx_cc_fips`(`cc_fips`),
INDEX `idx_cc_iso`(`cc_iso`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
-- Load data into table "country"
LOAD DATA LOCAL
INFILE 'GEODATASOURCE-COUNTRY.TXT'
INTO TABLE `country`
FIELDS TERMINATED BY '\t'
LINES TERMINATED BY '\r\n'
IGNORE 1 LINES;
-- Create table "world_cities_platinum"
CREATE TABLE [geodatasource].[dbo].[world_cities_platinum](
[continent_id] int,
[sub_continent_id] nvarchar(2) NOT NULL,
[ufi] int NOT NULL,
[uni] int NOT NULL,
[dsg] nchar(5) NOT NULL,
[cc_fips] nvarchar(2) NOT NULL,
[cc_iso] nvarchar(2) NOT NULL,
[full_name] nvarchar(200) NOT NULL,
[full_name_nd] nvarchar(200) NOT NULL,
[sort_name] nvarchar(200) NOT NULL,
[adm1_code] nvarchar(3) NOT NULL,
[adm1_full_name] nvarchar(200) NOT NULL,
[adm2_code] nvarchar(3) NOT NULL,
[adm2_full_name] nvarchar(200) NOT NULL,
[latitude] float NOT NULL,
[longitude] float NOT NULL,
[population] int NOT NULL
) ON [PRIMARY]
GO
CREATE INDEX [idx_continent_id] ON [geodatasource].[dbo].[world_cities_platinum]([continent_id]) ON [PRIMARY]
GO
CREATE INDEX [idx_sub_continent_id] ON [geodatasource].[dbo].[world_cities_platinum]([sub_continent_id]) ON [PRIMARY]
GO
CREATE INDEX [idx_continent] ON [geodatasource].[dbo].[world_cities_platinum]([continent_id], [sub_continent_id]) ON [PRIMARY]
GO
CREATE INDEX [idx_cc_iso] ON [geodatasource].[dbo].[world_cities_platinum]([cc_iso]) ON [PRIMARY]
GO
CREATE INDEX [idx_dsg] ON [geodatasource].[dbo].[world_cities_platinum]([dsg]) ON [PRIMARY]
GO
-- Create table "country"
CREATE TABLE [geodatasource].[dbo].[country](
[cc_fips] nvarchar(2) NOT NULL,
[cc_iso] nvarchar(2) NOT NULL,
[tld] nvarchar(3) NOT NULL,
[country_name] nvarchar(100) NOT NULL,
) ON [PRIMARY]
GO
CREATE INDEX [idx_cc_fips] ON [geodatasource].[dbo].[country]([cc_fips]) ON [PRIMARY]
GO
CREATE INDEX [idx_cc_iso] ON [geodatasource].[dbo].[country]([cc_iso]) ON [PRIMARY]
GO