tags:

views:

61

answers:

2

In a project at work i have to improve performance. The data of the app is spread over many databases. I was told that is better for organizing the data. Whatever. Is there a performance penalty when i do a select over some tables spread on several databases instead of a select on those tables in one database?

A: 

No, there shouldn't be a signifigant performance increase from spreading queries across different databases in mysql, assuming that the database are part of the same mysql install.

You'll do better to start with reducing the number of queries per page request, and zeroing in on individual queries that are taking a long time to complete.

Alan Storm
+1  A: 

depends on whether or not those databases are on the same physical server.

Brian Bay
Yes, they are all on the same mysql installation.
Andreas