...

View Full Version : Many tables in 1 DB vs. Few tables in Many DBs



johnnyb
08-30-2006, 07:49 PM
Hi,

I think that we've probably been over this before but I can't seem to find it so I'm asking again.

How much of a performance hit will I have if I have 1 database with 300 tables, versus 30 databases with 10 tables each? (the single database would have about 30x the traffic of any single database). I don't expect the tables themselves to be very long at all, perhaps a couple hundred records max.

Also, this will all run on the same server installation either way, so with 30 tables I don't get 30 MySQL servers. The traffic isn't going to be super heavy at all.

So, the question is, is it really worth setting up 30 DBs or should I just drop everything into one and keep it simple?

John

guelphdad
08-30-2006, 07:58 PM
if the data is related then use a single database. you can have hundreds of millions of records in a single table and mysql, properly tuned, with the table properly indexed, won't complain at all.

johnnyb
08-30-2006, 08:06 PM
That's what I thought but I wanted a second opinion before I told that to the client. Thanks.

John

felgall
08-31-2006, 04:52 AM
Having multiple databases will take up more space on the hard drive making things a lot less efficient than with one database.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum