Updated on 2023-03-06 GMT+08:00

RENAME USER Execution Failure

Scenario

The execution of the RENAME USER statement failed.

The failure may occur in MySQL-5.6.41.5.

Fault Analysis

The username does not exist but the memory indicates that it actually does.

Solution

Perform the following statements:

drop user 'xxx'@'%'; 
flush privileges;