In mysql, how can I specify that only one or more databases can be accessed by an existing user name? Other databases cannot be accessed.

Source: Internet
Author: User
Question 1: How does one implement read authorization only for the specified database with the specified user name? Question 2: the website has many Members who want to outsource some website functions to third-party companies, but I don't want to disclose member data to them, how to control the specified number of accesses to the member table or the target table... question 1: How does one implement read authorization only for the specified database with the specified user name?
Question 2: the website has many Members who want to outsource some website functions to third-party companies, but I don't want to disclose member data to them, how to control the access to specified data from the member table or the target table? For example, the member table can only access testuser1 and testuser2.

Reply content:

Question 1: How does one implement read authorization only for the specified database with the specified user name?
Question 2: the website has many Members who want to outsource some website functions to third-party companies, but I don't want to disclose member data to them, how to control the access to specified data from the member table or the target table? For example, the member table can only access testuser1 and testuser2.

Create another mysql account, assign permissions to the account, and specify the tables to be queryable and writable.

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.