Tips for Database Design of Website with international Users

i am developing a dating website, in which users can register from all over the World. The Dating section is divided into cities from again, all over the World. The Problem i see here is, i do not have a database that covers all cities around the Globe. I am confirming every user by hand so this gives me the opportunity to review the users city and country. Main main approach is, giving each city a "city_id" in the Database.

It's like if a person joins from New York, i give it the id US_NEWYORK If the person joins from Frankfurt they get the id DE_FRANKFURT

Both of those users still have their own City name in the Database and it's written down the same as they wrote it. So for example,

"Frankfurt" instead of "Frankfurt am Main" for the right name or, "NYC" instead of "New York" for the right name.

This way i can keep every users writing and can give the cities a special id and run all queries through that ID.

This is my very own solution and i think it's not so bad. Do you might have an Idea what i could do better?

I would like to kindly remember, that i would need every city from every country i'm running this service, if you would like to recommend i would get a database from somewhere :)

Thanks for reading.


Why don't you use a geocoding servers like or Google's geocoding API to find a canonical name for locations, and also a latitude/longitude. I assume you need the locations in some sort of canonical form so you can find closest matches, right? Well, latitude/longitude is the way to go there.

For instance, if you ask Google about "Frankfurt am Main", like so:

curl ''

You get back all this:

<?xml version="1.0" encoding="UTF-8"?>
  <formatted_address>Frankfurt, Germany</formatted_address>
   <long_name>Frankfurt am Main</long_name>
   <short_name>Frankfurt am Main</short_name>

looks quite comprehensive.

Need Your Help

.NET or COM HID iCLASS Smart Card Reader

c# .net smartcard winscard iso-15693

I have coding I almost always use with my Omnikey RFID CardMan 5321 smart cards. Problem is we received new cards today which are marked "HID iCLASS GL" which do not appear to be working well with...

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.