MDL-71016 gradeexport_xml: ensure user/grade idnumbers are encoded.