Word Cities/Towns/Countries database for MongoDB (or in JSON)?

javascript, jquery, lithium, mongodb, php

Solution

Take a look at GeoNames. You have to write your own script to parse the data and insert into MongoDB. Download GeoNames dump file here.

Problem

I'm developing a application using MongoDB. One of the standard functionality I want to provide on the front-end is the 'auto-suggest' feature as one types in the first few letters of a city (example: If I start typing 'Mu...', it should suggest to the user 'Mumbai/India'. I have seen a few threads here and also few sites on google which are databases of cites, essentially RDBMS based. Anyone here used or put-together a document database for such information of cities/countries? If so, I would love to hear about the source of the data and the steps they followed to import it in Lithium/Backbone/MongoDB application including any relevant learnings. EDIT: https://developers.google.com/places/documentation/autocomplete Has anyone used Facebook or Google Places API for looking up cities/countries in a live/production environment? Did it meet your needs in-terms of response speed and stability etc?

Original source