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 Tom Leo Lapworth wrote: > > On 13 Nov 2005, at 23:46, Brett Randall wrote: > >> Does anyone else have any ideas as to how I can utilise persistent >> database connections to a MySQL server via DBI, in order to speed up >> web queries, but without the 20 or so connections /per virtual server >> /that sit there waiting for something to happen? Should I be doing >> this differently? > > > I totally agree with the other posts - and this isn't a solution so much > as a work around... > > Put all your virtual hosts in one database, just start the table names > differently > > so instead of <virtual_db>.tablename have application_db.<virtual>_tablename > > This way apache only have to connect to one database. > > There may be all sorts of reasons you don't want to do this - and from a > design point of view > it's a bit messy - but it would solve your issue. > > Leo
signature.asc
Description: OpenPGP digital signature