MySQL Rights Management

Source: Internet
Author: User

For a user, there are three things about permissions: What permissions I have (how to view), how I delegate permissions to others (how to authorize), and how to retrieve permissions. In

There are three types of syntax that can be done in MySQL:

First, create a TIANJC user with a password of TIANJC: Create user ' TIANJC ' @ ' 192.168.1.113 ' identified by ' TIANJC ';

  

One, Authorization: Grant

If the user TIANJC on 192.168.1.113 is granted all permissions on the database pp: Grant all privileges on pp.* to ' TIANJC ' @ ' 192.168.1.113 ' with Grant OPTION;

Two, view permissions: Show grants

See the user on 192.168.1.113 for TIANJC permissions: Show grants for ' TIANJC ' @ ' 192.168.1.113 ';

Three cancellation authorization: REVOKE

If you cancel the authorization to TIANJC: REVOKE all privileges on pp.* from ' TIANJC ' @ ' 192.168.1.113 ';

Four, delete users: Drop user

MySQL Rights Management

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.