[drupal-devel] [bug] Allow both postgres and mysql database connections from within the same site.

drumm drupal-devel at drupal.org
Tue Aug 16 23:41:35 UTC 2005


Issue status update for 
http://drupal.org/node/19522
Post a follow up: 
http://drupal.org/project/comments/add/19522

 Project:      Drupal
 Version:      cvs
 Component:    database system
 Category:     bug reports
 Priority:     normal
 Assigned to:  adrian
 Reported by:  adrian
 Updated by:   drumm
-Status:       patch (code needs review)
+Status:       patch (code needs work)

Looks like the added constants in common.inc are leftover from something
else.




drumm



Previous comments:
------------------------------------------------------------------------

Sun, 27 Mar 2005 04:01:57 +0000 : adrian

Attachment: http://drupal.org/files/issues/multi-dbtype.diff (14.57 KB)

When I originally coded the multiple database support I noted the caveat
that only one database type was useable at a time due to the conflicting
function names, so including both database.pgsql.inc and
database.mysql.inc would cause a crash.


This was also brought up again when someone reopened the multi-db
functionality issue, and I am attaching the patch here.


I would love for this patch to get into 4.6 if possible. I don't
believe it's very invasive, and it fixes a long standing bug in the db
api. I have been using some form of this patch on Bryght for the last
3-4 months, and have not found any ill effects related to it.


I also clarified the db_set_active() comments a bit after I saw this
issue (http://drupal.org/node/13115).




------------------------------------------------------------------------

Tue, 21 Jun 2005 09:50:41 +0000 : Arto

Would love to have this in the core, but doesn't look like it's included
yet, neither in 4.6.1 nor in the latest snapshot. Any idea yet if and
when it'll be merged?




------------------------------------------------------------------------

Tue, 21 Jun 2005 09:53:06 +0000 : Arto

Oops, didn't intend to change the title of this bug report. Hereby
corrected.




------------------------------------------------------------------------

Thu, 23 Jun 2005 18:49:58 +0000 : adrian

Attachment: http://drupal.org/files/issues/multi-dbtype_0.diff (15.04 KB)

Here is an updated and working patch.


We use this patch on Bryght, as our hosting infrastructure is based on
postgres, but the sites themselves use mysql.


I originally wrote this patch as part of the install system however,
since I found myself in the situation where you had a mysql master
installation, and wanted to create a postgres site hosted 'underneath'
it. (the install.php file is multisite aware).







More information about the drupal-devel mailing list