A direct answer would be that you do not have to do anything: unless loginName is declared unique, or a key by itself, you can store the same value into it multiple times.
A better answer would be that you don't. You might have two tables instead:
Table: users
id
loginName
Table: images
id
user_id
image
So, if the loginName for a user is changed, instead of having to change all the rows in the table, you just change a single row in the users table since the user_id foreign key in the images table does not have to change.