XF 1.1 How to change one username by msql queries?


Active member

How can I change username let us say "Tom" into "Jerry"? I want to do this through mysql queries.

Thanks in advance.


Well-known member
It would be something like this:

update xf_user set username = 'Jerry' where username = 'Tom';
Disclaimer: I've never changed a username this way before, but I believe the above SQL should be correct. If for some reason it doesn't work properly, you can always just change it back with a similar query.


Well-known member
It'd be easier via the ACP, I'm not sure if there are other tables that need updating with the username.
Yes, that would be my worry as well, but if Barbossa desperately wants to try the SQL route, then he can try the above query.