Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

The method of adding users to mysql5.7

2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)06/01 Report--

This article mainly introduces the method of increasing users in mysql5.7, which has certain reference value and can be used for reference by friends who need it. I hope you will learn a lot after reading this article. Next, let the editor take you to learn about it.

Mysql5.7 's way to add users: first log in to mysql; and then execute the [CREATE USER 'test'@'localhost' IDENTIFIED BY' 1234users;] statement to add users.

Increase users

Example: create a test user with a password of 1234

MySQL-u root-p CREATE USER 'test'@'localhost' IDENTIFIED BY' 1234; # Local login CREATE USER 'test'@'%' IDENTIFIED BY' 1234; # remote login quit mysql-u test-p # to test whether the creation is successful

Delete user

Mysql-u root-p Delete FROM mysql.user Where User= "test" and Host= "localhost"; flush privileges; drop database testDB

Delete account and permissions:

Drop user user name @'%'; drop user user name @ localhost; thank you for reading this article carefully. I hope it will be helpful for everyone to share the ways to increase users on mysql5.7. At the same time, I also hope you will support us, pay attention to the industry information channel, and find out if you encounter problems. Detailed solutions are waiting for you to learn!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report