perl-modperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Clinton Gormley <>
Subject Re: Improving server performance with mod_perl 1.29 and DBI
Date Mon, 14 Nov 2005 11:22:58 GMT
On Mon, 2005-11-14 at 09:36 +0100, Tom Schindl wrote:
> I'm uncertain what you are telling here because I can use different
> databases while connected in a connection using the
> 1. Connect 2 DB (e.g. test)
> 2. Query: SELECT * FROM db1.tab1
> 3. Query: SELECT * FROM db2.tab1
> So there's no need to move all tables into one database, simply connect
> always to one database and use fully qualified SQL-Statements

There is one potential gotcha here, and that is if you are using
master-slave replication on your MySQL database, with replication
limited to certain databases.

MySQL looks for the 'use db_name' statements to decide what to
replicate, so, if you want to replicate db2, but not db1, and you do:

  use db1;
  update db2.table....

it won't do the right thing.

You would specifically have to do:

 use db2
 update db2.table OR update table

For more details, see "--replicate-do-db=db_name" on

View raw message