zoukankan      html  css  js  c++  java
  • 权限问题

    opsusr用户能执行drop procedure的单子;不能执行drop table的单子。

    查看操作用户权限

    GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, ALTER, EXECUTE, REPLICATION SLAVE, REPLICATION CLIENT, CREATE VIEW, SHOW VIEW, CREATE ROUTINE, ALTER ROUTINE, CREATE USER, EVENT, TRIGGER on *.* to 'opsusr'@'xxxx';

    没drop权限,但是为什么能drop procedure呢?

    文档

    The ALTER ROUTINE privilege is needed to alter or drop stored routines (procedures and functions).

    原来drop procedure的权限包含在alter routines里面了,alter routines包含alter以及drop存储过程和函数的权限,drop包含的是drop db,table,view权限

    另:truncate table也需要drop 权限

    The DROP privilege enables you to drop (remove) existing databases, tables, and views. The DROP privilege is required in order to use the statement ALTER TABLE ... DROP PARTITION on a partitioned table. The DROP privilege is also required for TRUNCATE TABLE. If you grant the DROP privilege for the mysql database to a user, that user can drop the database in which the MySQL access privileges are stored.

  • 相关阅读:
    swap函数的例子
    实现类似shared_ptr的引用计数
    使用new分配内存的类需要自己定义拷贝构造函数
    练习13.14 13.15 13.16
    查询单词,综合例子。
    无序容器
    关联容器操作
    关联容器概述
    文本查询程序
    shared_ptr与weak_ptr的例子
  • 原文地址:https://www.cnblogs.com/geek-ace/p/9335431.html
Copyright © 2011-2022 走看看