Following the instructions at this link, I'm trying to use the following syntax to create an user with a password
DROP DATABASE IF EXISTS forum;
CREATE DATABASE forum;
DELETE FROM mysql.user WHERE Host='localhost' AND User='forum_admin';
#In this way, the password will not be logged in mysql history
SELECT @password:=PASSWORD('forum_admin');
GRANT ALL PRIVILEGES ON forum.* TO 'forum_admin'@'localhost' IDENTIFIED BY PASSWORD '@password';
FLUSH PRIVILEGES;
However, the penultimate instruction gives this error
ERROR 1827 (HY000): The password hash doesn't have the expected format. Check if the correct password algorithm is being used with the PASSWORD() function.
So, how can I solve? I don't want to manually insert the result of the SELECT @password (as explained here or here for example), but I'd like to use those result to create automatically a new user.