From 3342593eac2440bbf70fa06a484b273d8e5e075e Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Wed, 7 Dec 2005 15:17:27 +0000 Subject: - Patch #38889 by rkerr: db_error and db_affected_rows did not work properly in presence of multiple database connections. --- includes/database.mysql.inc | 20 ++++++++++++-------- includes/database.pgsql.inc | 7 ++++--- 2 files changed, 16 insertions(+), 11 deletions(-) (limited to 'includes') diff --git a/includes/database.mysql.inc b/includes/database.mysql.inc index 04af5ea0a..c41e00494 100644 --- a/includes/database.mysql.inc +++ b/includes/database.mysql.inc @@ -63,7 +63,7 @@ function db_connect($url) { drupal_maintenance_theme(); drupal_set_title('Unable to select database'); print theme('maintenance_page', '

We were able to connect to the MySQL database server (which means your username and password is okay) but not able to select the database.

-

The MySQL error was: '. theme('placeholder', mysql_error()) .'.

+

The MySQL error was: '. theme('placeholder', mysql_error($connection)) .'.

Currently, the database is '. theme('placeholder', substr($url['path'], 1)) .'. The username is '. theme('placeholder', $url['user']) .' and the database server is '. theme('placeholder', $url['host']) .'.