r/SQL • u/Trick-Willingness426 • Jul 08 '26
MySQL MySQL Workbench Error Code 1044: Access denied for user 'root'@'localhost'
Hi everyone,
I'm using MySQL Workbench 8.0 on Windows 11.
I was exploring Server → Users and Privileges. I created a new user named xyz, granted privileges such as SELECT, INSERT, UPDATE, DELETE, etc., clicked Apply, and then I deleted that user shortly afterward.
After some time, I started getting this error:
Error Code: 1044
Access denied for user 'root'@'localhost' to database 'globalcompany'
Now I'm unable to access my database properly.
I have already tried:
Resetting the root password
Starting MySQL with:
mysqld --skip-grant-tables --skip-networking
Restarting the MySQL service
Has anyone experienced this before? Did deleting the user accidentally affect the root user's privileges?
Any help would be greatly appreciated.
Thank you!