We are using moodle 2.1 and whenever a teacher/student attempts a quiz, we receive "Error Writing to Database". The debugging is on and this is what shows up:
Debug info: Binary logging not possible. Message: Transaction level 'READ-COMMITTED' in InnoDB is not safe for binlog mode 'STATEMENT'
INSERT INTO mdl_question_usages (contextid,component,preferredbehaviour) VALUES(?,?,?)
[array (
0 => '1172',
1 => 'mod_quiz',
2 => 'deferredfeedback',
)]
INSERT INTO mdl_question_usages (contextid,component,preferredbehaviour) VALUES(?,?,?)
[array (
0 => '1172',
1 => 'mod_quiz',
2 => 'deferredfeedback',
)]
Stack trace:
- line 396 of \lib\dml\moodle_database.php: dml_write_exception thrown
- line 878 of \lib\dml\mysqli_native_moodle_database.php: call to moodle_database->query_end()
- line 920 of \lib\dml\mysqli_native_moodle_database.php: call to mysqli_native_moodle_database->insert_record_raw()
- line 67 of \question\engine\datalib.php: call to mysqli_native_moodle_database->insert_record()
- line 93 of \question\engine\lib.php: call to question_engine_data_mapper->insert_questions_usage_by_activity()
- line 198 of \mod\quiz\startattempt.php: call to question_engine::save_questions_usage_by_activity()
I have checked the module settings and the quiz and everything seems normal. I have created my own quiz to recreate this issue and try to determine the problem and no luck.
Any help would be appreciated.
Thank you
Bonnie