-
Bug
-
Resolution: Fixed
-
Minor
-
1.8.1
-
None
-
MOODLE_18_STABLE
-
MOODLE_19_STABLE
Excel sometimes generates CSV files where some rows have less fields than others when the last fields on a row are empty.
e.g.:
username,course1,role1,course2,role2
userid1,CF01,5,CF02,3
userid2,CF05,5
If the above file is uploaded then moodle fills in the missing fields in the 'userid2' row with CF02,3 from the row above.
Better handling would be to assume those fields are blank.
Caused by failure to clear $record variable between processing lines of CSV file.
Solution is to add "unset($record);" on line 359 of admin/uploaduser.php (just after unset($user); ):
- will be (partly) resolved by
-
MDL-11996 bulk user upload - improvements, fixes and cleanup
-
- Closed
-