Can not find data record in database table course.

More information about this error

Debug info: SELECT * FROM {course} WHERE id = ?
[array (
0 => 8,
)]
Error code: invalidrecord
Stack trace:
  • line 1546 of \lib\dml\moodle_database.php: dml_missing_record_exception thrown
  • line 1522 of \lib\dml\moodle_database.php: call to moodle_database->get_record_select()
  • line 588 of \lib\datalib.php: call to moodle_database->get_record()
  • line 80 of \calendar\view.php: call to get_course()