summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorwebchick <webchick@24967.no-reply.drupal.org>2012-04-12 00:21:02 -0700
committerwebchick <webchick@24967.no-reply.drupal.org>2012-04-12 00:21:02 -0700
commit541cf80f64edcf1b520c20073455dd9c1557ecfe (patch)
tree5faca8390e799dab7ac3ac53ce8658e2ce1e33c5
parent464808fb43c82ebb4beb3cd524651b4464315edf (diff)
downloadbrdo-541cf80f64edcf1b520c20073455dd9c1557ecfe.tar.gz
brdo-541cf80f64edcf1b520c20073455dd9c1557ecfe.tar.bz2
Issue #1171866 by sun, catch, Alan Evans, bvirtual, frob, btmash: Fixed Enforced fetching of fields/columns in lowercase breaks third-party integration.
-rw-r--r--includes/database/mysql/database.inc2
-rw-r--r--includes/database/mysql/schema.inc2
-rw-r--r--includes/database/pgsql/database.inc2
-rw-r--r--includes/database/sqlite/database.inc8
4 files changed, 4 insertions, 10 deletions
diff --git a/includes/database/mysql/database.inc b/includes/database/mysql/database.inc
index e024a7f39..7278a2bc8 100644
--- a/includes/database/mysql/database.inc
+++ b/includes/database/mysql/database.inc
@@ -46,8 +46,6 @@ class DatabaseConnection_mysql extends DatabaseConnection {
PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => TRUE,
// Because MySQL's prepared statements skip the query cache, because it's dumb.
PDO::ATTR_EMULATE_PREPARES => TRUE,
- // Force column names to lower case.
- PDO::ATTR_CASE => PDO::CASE_LOWER,
);
parent::__construct($dsn, $connection_options['username'], $connection_options['password'], $connection_options['pdo']);
diff --git a/includes/database/mysql/schema.inc b/includes/database/mysql/schema.inc
index 4e88fa169..7268f2d89 100644
--- a/includes/database/mysql/schema.inc
+++ b/includes/database/mysql/schema.inc
@@ -381,7 +381,7 @@ class DatabaseSchema_mysql extends DatabaseSchema {
// Returns one row for each column in the index. Result is string or FALSE.
// Details at http://dev.mysql.com/doc/refman/5.0/en/show-index.html
$row = $this->connection->query('SHOW INDEX FROM {' . $table . "} WHERE key_name = '$name'")->fetchAssoc();
- return isset($row['key_name']);
+ return isset($row['Key_name']);
}
public function addPrimaryKey($table, $fields) {
diff --git a/includes/database/pgsql/database.inc b/includes/database/pgsql/database.inc
index d42a1cc3c..d80b47551 100644
--- a/includes/database/pgsql/database.inc
+++ b/includes/database/pgsql/database.inc
@@ -62,8 +62,6 @@ class DatabaseConnection_pgsql extends DatabaseConnection {
PDO::ATTR_EMULATE_PREPARES => TRUE,
// Convert numeric values to strings when fetching.
PDO::ATTR_STRINGIFY_FETCHES => TRUE,
- // Force column names to lower case.
- PDO::ATTR_CASE => PDO::CASE_LOWER,
);
parent::__construct($dsn, $connection_options['username'], $connection_options['password'], $connection_options['pdo']);
diff --git a/includes/database/sqlite/database.inc b/includes/database/sqlite/database.inc
index b4e41b527..ea91e9143 100644
--- a/includes/database/sqlite/database.inc
+++ b/includes/database/sqlite/database.inc
@@ -37,7 +37,7 @@ class DatabaseConnection_sqlite extends DatabaseConnection {
/**
* All databases attached to the current database. This is used to allow
* prefixes to be safely handled without locking the table
- *
+ *
* @var array
*/
protected $attachedDatabases = array();
@@ -46,10 +46,10 @@ class DatabaseConnection_sqlite extends DatabaseConnection {
* Whether or not a table has been dropped this request: the destructor will
* only try to get rid of unnecessary databases if there is potential of them
* being empty.
- *
+ *
* This variable is set to public because DatabaseSchema_sqlite needs to
* access it. However, it should not be manually set.
- *
+ *
* @var boolean
*/
var $tableDropped = FALSE;
@@ -68,8 +68,6 @@ class DatabaseConnection_sqlite extends DatabaseConnection {
'pdo' => array(),
);
$connection_options['pdo'] += array(
- // Force column names to lower case.
- PDO::ATTR_CASE => PDO::CASE_LOWER,
// Convert numeric values to strings when fetching.
PDO::ATTR_STRINGIFY_FETCHES => TRUE,
);