Problem importing users with CSV file with already created users

Problem importing users with CSV file with already created users

by Pablo Vaccarezza -
Number of replies: 1

Hello, already searched about this but couldnt find a good response. I am importing users with the "admin/tool/uploaduser/index.php" tool from a CSV file from another DB with the following format so they keep the same credentials (username,passwd and email) from the other site and are created and matriculated automaticaly in a course in Moodle. The file has the following example format:

username,password,email,firstname,lastname,course1
username1,16501a6b530bc3c65c64e82a0dceb0e4,user1@gmail.com,Name1,Lastname1,CourseShortName
username2,jk23j2j32k3j2j3k2jk3j2k3jk2j3kj2j3k2jk3,user2@gmail.com,Name2,Lastname2,CourseShortName

The problem appears with pre-existent created users in Moodle with the same email as the CSV but different username. Although I selected the "add new and updted existent users" they are ignored and skipped with the legend "Duplicated address" in the email field.

Is there any way to avoid this and force Moodle to overwrite existent users with the data of the CSV file? That meas updating the username/password fields too.

Thanks in advance.

Average of ratings: -
In reply to Pablo Vaccarezza

Problem importing users with CSV file with already created users

by John Provasnik -
Picture of Particularly helpful Moodlers Picture of Testers
I'd suggest re-uploading the file with just the "Update existing users" option