- Learn MySQL
- MySQL - Home
- MySQL - Introduction
- MySQL - Installation
- MySQL - Administration
- MySQL - PHP Syntax
- MySQL - Connection
- MySQL - Create Database
- MySQL - Drop Database
- MySQL - Select Database
- MySQL - Data Types
- MySQL - Create Tables
- MySQL - Drop Tables
- MySQL - Insert Query
- MySQL - Select Query
- MySQL - Where Clause
- MySQL - Update Query
- MySQL - Delete Query
- MySQL - Like Clause
- MySQL - Sorting Results
- MySQL - Using Join
- MySQL - NULL Values
- MySQL - Regexps
- MySQL - Transactions
- MySQL - Alter Command
- MySQL - Indexes
- MySQL - Temporary Tables
- MySQL - Clone Tables
- MySQL - Database Info
- MySQL - Using Sequences
- MySQL - Handling Duplicates
- MySQL - SQL Injection
- MySQL - Database Export
- MySQL - Database Import
ERROR 1396 (HY000): Operation CREATE USER failed for 'root'@'localhost'?
In the system, the root is defined by another name as well as password. Then the user is created as a root with the help of the create command. This will result in the ERROR 1396.
The query for this is given as follows −
mysql> create user 'root'@'localhost' identified by 'root123';
After executing the above query, the following error is obtained −
ERROR 1396 (HY000): Operation CREATE USER failed for 'root'@'localhost'
The user can be created with another name and password successfully. This is given as follows −
mysql> create user 'John'@'localhost' identified by 'john123'; Query OK, 0 rows affected (0.14 sec)
Now, the user John has been created successfully with the given password.
- Related Articles
- Fix: ERROR 1396 (HY000): Operation CREATE USER failed in MySQL?
- Solve ERROR 1396 (HY000): Operation DROP USER failed for 'user'@'localhost' in MySql?
- Resolve error 1045 (28000) access denied for user 'root'@'localhost' (using password: YES)?
- Rename Root @ localhost username in MySQL?
- Error Failed to load resource in SAPUI5 application
- MySQL Stored Procedure DEFINER=`root`@`%` is not working in localhost?
- Setting detailed error notification about failed login in SAP HANA
- MySQL Error ERROR 1099 (HY000): Table was locked with a READ lock and can't be updated
- Getting error while running SAP oData service “HTTP Open failed: PLUGIN_NOT_ACTIVE”
- How to calculate root mean square error for linear model in R?
- Resolve java.sql.SQLException: No suitable driver found for localhost test?
- Running Docker Container as a Non Root User
- Cast to ObjectId failed for value in MongoDB?
- Fix ERROR 1093 (HY000): You can't specify target table for update in FROM clause while deleting the lowest value from a MySQL column?
- Reset the root user password on rhel7 xcentos7 x