Dba_objects table if you want to query other objects. 2. Batch Reclaim system privileges, recover all system privileges of user CHENMH SELECT ' REVOKE ' | | privilege| | ' from CHENMH; ' From Dba_sys_privs WHERE grantee= ' chenmh '; Copy the stitched SQL out to execute the query. 3. Bulk recall of Role permissions SELECT ' REVOKE ' | | granted_role| | ' from CHENMH; ' From Dba_role_privs WHERE grantee= '
= ' ZHANG ';You can query the Dba_objects table if you want to query other objects.2. Batch Reclaim system privileges, recover all system privileges of user CHENMHSELECT ' REVOKE ' | | privilege| | ' from CHENMH; ' From Dba_sys_privs WHERE grantee= ' chenmh ';Copy the stitched SQL out to execute the query.3. Bulk recall of Role permissionsSELECT ' REVOKE ' | | granted_role| | ' from CHENMH; ' From Dba_role
--Create a User Yong2,yong2 table space for users, a temporary tablespace of temp,users tablespace size of 10M, the password immediately expires, the user locked.CREATE USER Yong2Identified by QwerDEFAULT tablespace UsersTemporary Tablespace TempQUOTA 10m on usersPASSWORD EXPIREAccount LOCK;--Modify the yong2 password to inspur123 and unlock the user.ALTER USER yong2 identified by inspur123;ALTER USER yong2 account UNLOCK;--Give user yong2 permission to create a sessionGRANT create session to Yo
1.GRANT Assign PermissionsThe common set of system permissions has the following three:Connect (basic connection), RESOURCE (program development), DBA (database management)The common data object permissions are the following five:All on data object name, SELECT on data object name, UPDATE on data object name,DELETE on data object name, INSERT on data object name, ALTER on data object nameGRANT CONNECT, RESOURCE to user name;
• Authorization via Grantsyntax:GRANT object_priv[(columns)][on object] to {user|role|public} [with GRANT OPTION] • Recycling through revokesyntax:REVOKE object_priv[(columns)][on object] from {user[,user...]| Role|public} [CASCADE constrints] Revoke system permissions with admin OPTION (permission reclamation does not
1, with admin option
With admin option means that the user granted this permission has the right to grant a permission (such as create any table) to another user or role, and cancellation is not cascaded.
If you grant a system permission to create session with admin option,
The MySQL permissions system revolves around two concepts:Authentication, determining whether a user is allowed to connect to a database serverAuthorization, determines whether the user has sufficient permissions to execute the query request, and so on.If the authentication is unsuccessful, then the authorization must not be carried out.revoke is similar to Grant's syntax, just to replace the keyword "to" with "from"Table grant and
DescriptionWhen a owner-not_owner_user that is not my_table This table tries to grant my_table permission, an error occurs:Error report:sql error:ora-01720:grant option does not exist for ' owner_schema '. My_table ' 01720. 00000- "grant option does not exist for '%s.%s '"
permissions granted to MySQL users.The syntax of revoke is similar to that of grant. You only need to replace the keyword "to" with "from:
1 grant all on *.* to dba@localhost; 2 revoke all on *.* from dba@localhost;
VIII. Considerations for MySQL grant and
SELECT, INSERT, UPDATE, delete on testdb.orders to Dba@localhost;
Here, when you authorize multiple tables for a user, you can execute the above statements more than once. For example:
Grant Select (user_id,username) on smp.users to mo_user@ '% ' identified by ' 123345 ';
4. Grant acts on the columns in the table:
5. Grant fun
. Represents the password required for this authorization. 5. Other options (refer to: http://blog.csdn.net/haiross/article/details/51251571 by Haiross) [With GRANT OPTION] Max_queries_per_hour Count Max_updates_per_hour Count Max_connections_per_hour Count Max_user_connections Count About creating a MySQL User: 1.CREATE USER After this method is created, you also need to follow through
Administrator Password Recovery:Find ideas:Turn off service--Modify Service Script add startup option--Start service--Change password with update command--shut down service--Modify script--Restart service--skip-grant-tables Skip Authorization Form--skip-networkding disables the network and prevents other users from logging on through the network.#systemctl Stop Mysqld#vim/etc/init.d/mysqld...Case ' $mode '
The database administrator can grant users permission to manipulate dataGrank: Granting PermissionsGrank onTo [with Grank OPTION]; -----A user who has access to some kind of permission can grant this permission to another userFor example:Grank SELECTOn TABLE Studentto U1;Grank all privileges-------All permissionsOn TABLE Student,courseto U2,U3;
Oracle
When a user is granted system privileges with admin option, he can grant this permission to other users, roles, and do not cascade the permissions that he grants to other users when revoke is granted the user's system privileges. If a user P system permission is granted with the WITH admin
With grant option: permissions are revoked in revoke cascade.
With admin option: permissions are not revoked in revoke cascade.
Reprinted on http://blog.chinaunix.net/u2/75347/showart_1129674.html
Similarities:-Both can be used only when user permission is granted or when
When you give user permissions or role, you often use the WITH admin option and with GRANT option,In use, it may be easy to confuse the situation, now the similarities and differences between their points are summarized as follows:Same point:-Two can both give the userPermissions, you can also use it when assigning a roleGRANT CREATE SESSION to EMI with ADMIN
With admin option is used for system permission authorization, and with grant option is used for object authorization.
However, when a user is granted system permissions with the with admin option, the user can grant the system permissions to other users or roles, but the
1. With admin optionwith admin option means that the user granted the permission has the right to grant a permission (such as create any table) to another user or role, and the cancellation is not cascading. If you grant a system permission to create session with admin option, and then a CREATE session permission is gr
permissions include some object-related content. Such as select any table and execute any procedure. These and object permissions overlap.[Experiment]SQL> create user mytest identified by mytest;User CreatedSQL> grant connect, resource to mytest;Grant succeededSQL> grant select any table to mytest;Grant succeededSQL>
The owner of the object assigns permissions to a user (for example: TestUser1)Grant SELECT, update on Bd_corp to TestUser1 [with GRANT OPTION]1. If you have with GRANT optionThen user testuser1 can pass Select, update permissions to other users (such as TestUser2)Grant Selec
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.