FWIW. Take a look at <a href="http://drupal.org/node/131524">http://drupal.org/node/131524</a> [1] for some common methods for working with external data.<br><br>If you're in Barcelona, I will be addressing this again in the session "Using External Data with Drupal."
<br><br>I'm also going to have the "Enterprise Drupal" talk (again). Only this time there is no debate element. :-)<br><br>- Ken Rickard<br>agentrickard<br><br>[1] And the download <a href="http://ken.therickards.com/wp-content/uploads/2007/03/OSCMS.pdf">
http://ken.therickards.com/wp-content/uploads/2007/03/OSCMS.pdf</a><br><br><br><div><span class="gmail_quote">On 8/16/07, <b class="gmail_sendername">J-P Stacey</b> <<a href="mailto:jp.stacey@torchbox.com">jp.stacey@torchbox.com
</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Tao Starbow wrote:<br>> This is one of the cooler, not-so-well known drupal features. In
<br>> settings.php you can define $db_url as an array<br>> $db_url['default'] = normal drupal string<br>> $db_url['backoffice'] = other mysql connect string<br>><br>> then you use db_set_active( db_key ) to switch between them as needed.
<br><br>Is this a standard core feature, enabled by default? I feel like saying "why<br>wasn't I told about this before?" :)<br><br>One of the big problems we have is that many developers working on a given<br>
codebase: this means the codebase is in subversion and people check it out<br>to their own machines, work on it, check changes back in.<br><br>Some developers develop on the same machine, because their desktops are<br>WinXX and setting up LAMP stacks takes time. On this machine, whilst they
<br>can check out site-specific codebases to e.g.<br>sites/developername-<a href="http://clientname-devel.example.com">clientname-devel.example.com</a> and hence develop in their<br>own sandboxes, it's difficult to keep the site under revision and yet not
<br>have people be forced to share a database by settings.php .<br><br>But with the above a high-priority module could switch quickly and cleanly<br>between developers' own sandboxed databases: does that sound right? How
<br>would you sneak in before any of the other modules? Would the following at<br>the end of settings.php be sufficient:<br><br> db_set_active($_SERVER['HTTP_HOST']); // defaults to 'default'<br><br>
Or is that too hacky? Can you even call a function from within settings.php<br>(notwithstanding the argument of "would you want to?")<br><br>Somewhere among all this is functionality to make Drupal a good deal more
<br>"enterprise", for whatever that hackneyed term is worth. Transparently<br>distributed development for large-scale, independent CMS teams on their<br>clients' behalf.<br><br>Cheers,<br>J-P<br>--<br>J-P Stacey
<br>+44 (0)1608 811870<br><a href="http://torchbox.com">http://torchbox.com</a><br></blockquote></div><br>