无法在 phpMyAdmin 中查看数据库权限

Posted

技术标签:

【中文标题】无法在 phpMyAdmin 中查看数据库权限【英文标题】:Can't view db privileges in phpMyAdmin 【发布时间】:2021-04-24 13:14:16 【问题描述】:

无法查看数据库权限 http://localhost:8080/server_privileges.php?db=XXXX&checkprivsdb=nb&viewing_mode=db

==> 错误:#1267 - 排序规则的非法混合

全新安装 phpMyAdmin 5.0.4 Apache/2.4.38 (Debian) 数据库客户端版本:libmysql - mysqlnd 7.4.13 PHP 扩展:mysqli 文档 curl 文档 mbstring 文档 PHP版本:7.4.13

( SELECT `User`, `Host`, `Select_priv`, `Insert_priv`, `Update_priv`, `Delete_priv`, `Create_priv`, `Drop_priv`, `Grant_priv`, `Index_priv`, `Alter_priv`, `References_priv`, `Create_tmp_table_priv`, `Lock_tables_priv`, `Create_view_priv`, `Show_view_priv`, `Create_routine_priv`, `Alter_routine_priv`, `Execute_priv`, `Event_priv`, `Trigger_priv`, '*' AS `Db`, 'g' AS `Type` FROM `mysql`.`user` WHERE NOT (`Select_priv` = 'N' AND `Insert_priv` = 'N' AND `Update_priv` = 'N' AND `Delete_priv` = 'N' AND `Create_priv` = 'N' AND `Drop_priv` = 'N' AND `Grant_priv` = 'N' AND `References_priv` = 'N' AND `Create_tmp_table_priv` = 'N' AND `Lock_tables_priv` = 'N' AND `Create_view_priv` = 'N' AND `Show_view_priv` = 'N' AND `Create_routine_priv` = 'N' AND `Alter_routine_priv` = 'N' AND `Execute_priv` = 'N' AND `Event_priv` = 'N' AND `Trigger_priv` = 'N')) UNION ( SELECT `User`, `Host`, `Select_priv`, `Insert_priv`, `Update_priv`, `Delete_priv`, `Create_priv`, `Drop_priv`, `Grant_priv`, `Index_priv`, `Alter_priv`, `References_priv`, `Create_tmp_table_priv`, `Lock_tables_priv`, `Create_view_priv`, `Show_view_priv`, `Create_routine_priv`, `Alter_routine_priv`, `Execute_priv`, `Event_priv`, `Trigger_priv`, `Db`, 'd' AS `Type` FROM `mysql`.`db` WHERE 'nb' LIKE `Db`     AND NOT (`Select_priv` = 'N' AND `Insert_priv` = 'N' AND `Update_priv` = 'N' AND `Delete_priv` = 'N' AND `Create_priv` = 'N' AND `Drop_priv` = 'N' AND `Grant_priv` = 'N' AND `References_priv` = 'N' AND `Create_tmp_table_priv` = 'N' AND `Lock_tables_priv` = 'N' AND `Create_view_priv` = 'N' AND `Show_view_priv` = 'N' AND `Create_routine_priv` = 'N' AND `Alter_routine_priv` = 'N' AND `Execute_priv` = 'N' AND `Event_priv` = 'N' AND `Trigger_priv` = 'N')) ORDER BY `User` ASC, `Host` ASC, `Db` ASC;

错误:#1267 - 操作“”的排序规则 (utf8mb4_general_ci,COERCIBLE) 和 (utf8mb4_unicode_ci,COERCIBLE) 的非法混合

【问题讨论】:

【参考方案1】:

设置 collat​​ion_connection = 'utf8mb4_general_ci'

【讨论】:

请在您的答案中添加一些解释,以便其他人可以从中学习

以上是关于无法在 phpMyAdmin 中查看数据库权限的主要内容,如果未能解决你的问题,请参考以下文章

phpmyadmin的只读安装

phpMyAdmin 报告“无权限”

如何在 phpMyAdmin 中轻松访问所有帖子标题以从 WooCommerce 进行编辑?

无法解析 config.inc.php 的 phpMyAdmin 权限

无法访问 phpmyadmin(403 权限错误)

更改权限后,Phpmyadmin 无法在 ubuntu xampp 中工作