HowTo: Mysql Update Password SQL Command

by on December 6, 2012 · 0 comments· LAST UPDATED December 6, 2012

Fig.01: Mysql Updating / Changing password (click to enlarge)

The sql syntax is as follows and you must login as root (mysql server administrator) user account:

SET PASSWORD FOR 'user'@'host' = PASSWORD('password');

OR

UPDATE mysql.user SET Password=PASSWORD('password') WHERE User='user' AND Host='host';

You must flush the privileges

FLUSH PRIVILEGES;
TwitterFacebookGoogle+Found an error/typo on this page? Help us!

Examples and usage: MySQL Change a User Password

{ 0 comments… add one now }

Leave a Comment

Tagged as: