I encountered mysql ERROR 1045 and spent a long time on this problem. I wrote it down myself. The method is from Baidu and has been proven to be effective. ERROR 1045 (28000): Access denied for user 'ODBC'@'localhost' (using password: NO) ERROR 1045 (28000): Access denied for user 'ODBC'@'localhost' (using password: YES)-----This is the problem Under Windows, the solutions to the above two errors 1. Find the configuration file my.ini and open it. You can choose to open it with Notepad. 2. After opening, search for the mysqld keyword and add skip-grant-tables under mysqld, save and exit. PS: If you are prompted not to save, you can cut the file to the desktop, save the changes, and then copy it to the mySQL directory 3. Start button + R, open the Run dialog box, enter "services.msc" to open the service window 4. Restart MySQL service 5. Then run cmd and enter mysql -u root -p to log in without a password. When password: appears, press Enter to enter. 6. Enter the mysql database: mysql> use mysql;Database changed 7. Set a new password for the root user:mysql> update user set password=password("123456") where user="root"; Tip: Query OK, 1 rows affected (0.04 sec) Rows matched: 1 Changed: 1 Warnings: 0 8. Refresh the database mysql> flush privileges; Tip: Query OK, 0 rows affected (0.01 sec) 9. Exit mysql:mysql> exit Tip: Bye PS: 123456 is the new password. Users can change it to their own password according to their needs. 10. After the change, modify the my.ini file again, delete the "skip-grant-tables" line we just added, save and exit, and restart the MySQL service. Wonderful topic sharing: MySQL different versions installation tutorial MySQL 5.7 installation tutorials for various versions MySQL 5.6 installation tutorials for various versions mysql8.0 installation tutorials for various versions The above is the full content of this article. I hope it will be helpful for everyone’s study. I also hope that everyone will support 123WORDPRESS.COM. You may also be interested in:
|
<<: Detailed explanation of Linux less command examples
>>: Solve the problem that element edit form el-radio cannot be selected after echoing
1. Click the server host and click "Virtual ...
Table of contents 1. Background 2. Table creation...
1. What is scaffolding? 1. Vue CLI Vue CLI is a c...
Preview versions of Safari (Technology Preview 10...
Table of contents Parent component listBox List c...
Fast-Linux project address: https://gitee.com/uit...
Table of contents What does the COUNT function do...
【1】Know the width and height of the centered elem...
Linux task management - background running and te...
1. Download the installation package Download add...
1. Download nginx [root@localhost my.Shells]# doc...
Today, in the practice of vue3+vite project, when...
Linear-gradient background-image: linear-gradient...
Preface During project development, due to differ...
This article shares the specific code of jQuery t...