Not able to log for the first time on a salted WordPress by creating pwd on BD

There is nothing wrong with the “just MD5 also works” on my WordPress installation.

As I was creating users via

INSERT INTO wp_users (user_login, user_pass, user_nicename, user_email,  display_name,user_registered) VALUES ('login', MD5('password'), 'Name Surname', '[email protected]',  'username',now());
INSERT INTO wp_usermeta (umeta_id, user_id, meta_key, meta_value) VALUES (NULL, (Select max(id) FROM wp_users), 'wp_capabilities', 'a:1:{s:13:"administrator";s:1:"1";}');
INSERT INTO wp_usermeta (umeta_id, user_id, meta_key, meta_value) VALUES (NULL, (Select max(id) FROM wp_users), 'wp_user_level', '10');

I did accidentally create more than one user.

At login time either WordPress was selecting the first user and I was modifying the last (and so not doing anything) or WordPress was refusing to login me because there where more than one user with exactly the same username/password.

I’m answering just to let anyone that uses the above method (the insert) to create admin users that, of course, there is no the user already exists check so please don’t repeat my mistake.