I just installed moodle 4.0.1 through cpanel. I tried creating a Simple Calculated Question and I got the error below. Any help would be greatly appreciated. Thank you!
Can't find data record in database.
q.generalfeedback, q.generalfeedbackformat, q.defaultmark, q.penalty, q.qtype,
q.length, q.stamp, q.timecreated, q.timemodified,
q.createdby, q.modifiedby, qbe.idnumber,
qc.contextid,
qv.status,
qv.id as versionid,
qv.version,
qv.questionbankentryid
FROM {question} q
JOIN {question_versions} qv ON qv.questionid = q.id
JOIN {question_bank_entries} qbe ON qbe.id = qv.questionbankentryid
JOIN {question_categories} qc ON qc.id = qbe.questioncategoryid
WHERE q.id = :id
[array (
'id' => 0,
)]
Error code: invalidrecordunknown
- line 1674 of /lib/dml/moodle_database.php: dml_missing_record_exception thrown
- line 624 of /question/engine/bank.php: call to moodle_database->get_record_sql()
- line 587 of /cache/classes/loaders.php: call to question_finder->load_for_cache()
- line 1792 of /cache/classes/loaders.php: call to cache->get_implementation()
- line 405 of /cache/classes/loaders.php: call to cache_application->get_implementation()
- line 480 of /question/engine/bank.php: call to cache->get()
- line 255 of /question/engine/bank.php: call to question_finder->load_question_data()
- line 273 of /question/engine/bank.php: call to question_bank::load_question_data()
- line 217 of /question/bank/editquestion/question.php: call to question_bank::load_question()
Need to provide courseid or cmid to print_question.
Error code: missingcourseorcmid
- line 109 of /question/bank/editquestion/question.php: moodle_exception thrown