Building a multi-city classifieds system like Kijiji

Questions about the MySQL, PostgreSQL, and most other databases, as well as using it with PHP can be asked here.

Moderator: General Moderators

Post Reply
alex.barylski
DevNet Evangelist
Posts: 6267
Joined: Tue Dec 21, 2004 5:00 pm
Location: Winnipeg

Building a multi-city classifieds system like Kijiji

Post by alex.barylski »

Interesting how Kijii doesn't allow you to search all of Canada (or any country) that I have been able to confirm.

I assume this is because each city, uses a separate database, for scalability, etc?

WordPress MU does something very similar, in that it uses a separate database for each of the blogs it creates.

Does it make sense then, to create a separate table of ads for each city-prov? Or would it make more sense to just use a separate database for each city? I assume this barrier is what prevents Kijiji from enabling global searches, as switching from one city to another DB connection would be quite slow.

Currently our system is implemented as each ad having a city ID, so all ads are stored in a single table, which is OK for searching but would multiple databases be more efficient?

According to Matt Mullenweg in their experience, multiple tables has proven to be more efficient.

What saysyou DB champs? :)

Cheers,
Alex
Post Reply