Brian
Brian

Reputation: 27392

Is there any computational reason for keeping MySQL tables in separate dbs?

I know it can be convenient for a programmer to group different sets of tables into different databases. Is a computational benefit to doing this?

Upvotes: 2

Views: 179

Answers (2)

Bill Karwin
Bill Karwin

Reputation: 562260

There's no advantage or difference that comes from putting MySQL tables in different databases, except that databases provide a kind of namespacing. That is, you can have two tables with the same name, in different databases.

Otherwise, as long as the databases are managed by the same instance of MySQL Server, you can do anything as if the tables are in one database, including JOIN and even FOREIGN KEY references between the tables.

See also "MySQL: Many tables or many databases?"

Upvotes: 4

gahooa
gahooa

Reputation: 137282

No, not with MySQL. However, various table handlers have different options for where the physical data is stored. That can be advantageous if you need to get very high performance (for example, putting different data on different disks).

Upvotes: 0

Related Questions