From 7281232b884ccff2b533624d8adb8a13bcbcc295 Mon Sep 17 00:00:00 2001 From: "Alexander M. Turek" Date: Mon, 19 Apr 2004 22:10:42 +0000 Subject: [PATCH] Illegal mix of collations. There's more where this came from... Will do the rest tomorrow. --- ChangeLog | 1 + server_privileges.php | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index b11a2be03..643a3a85c 100755 --- a/ChangeLog +++ b/ChangeLog @@ -10,6 +10,7 @@ $Source$ * config.inc.php, Documentation.html, libraries/config_import.lib.php: Updated path to MySQL's searchable online documentation. * ChangeLog: Recoded to UTF-8. + * server_privileges.php: Illegal mix of collations. 2004-04-19 Marcel Tschopp * libraries/export/sql.php, libraries/export/latex.php: Fixed a few diff --git a/server_privileges.php b/server_privileges.php index e8d4fefbc..3b1346b78 100644 --- a/server_privileges.php +++ b/server_privileges.php @@ -1061,7 +1061,7 @@ if (empty($adduser) && empty($checkprivs)) { if (empty($dbname)) { $sql_query = 'SELECT * FROM `db` WHERE `Host` = "' . $hostname . '" AND `User` = "' . PMA_sqlAddslashes($username) . '" ORDER BY `Db` ASC;'; } else { - $sql_query = 'SELECT `Table_name`, `Table_priv`, IF(`Column_priv` = "", 0, 1) AS "Column_priv" FROM `tables_priv` WHERE `Host` = "' . $hostname . '" AND `User` = "' . PMA_sqlAddslashes($username) . '" AND `Db` = "' . $dbname . '" ORDER BY `Table_name` ASC;'; + $sql_query = 'SELECT `Table_name`, `Table_priv`, IF(`Column_priv` = ' . (PMA_MYSQL_INT_VERSION >= 40100 ? '_latin1 ' : '') . ' "", 0, 1) AS "Column_priv" FROM `tables_priv` WHERE `Host` = "' . $hostname . '" AND `User` = "' . PMA_sqlAddslashes($username) . '" AND `Db` = "' . $dbname . '" ORDER BY `Table_name` ASC;'; } $res = PMA_DBI_query($sql_query, NULL, PMA_DBI_QUERY_STORE); if (PMA_DBI_affected_rows() == 0) {