-
Bug
-
Resolution: Fixed
-
Minor
-
None
-
2.2.2
-
None
-
MOODLE_22_STABLE
Moodle 2.2.2.
When clicking the config tab, an error occurs. Developer mode displays:
A Moodle error occurred:
Error reading from database
Debug info:
SQLState: 42000
Error Code: 169
Message: [Microsoft][SQL Server Native Client 10.0][SQL Server]A column has been specified more than once in the order by list. Columns in the order by list must be unique.
SELECT DISTINCT course.id AS courseid, course.shortname AS name, course.fullname AS tooltip, settings.display, settings.groupsdisplay, settings.id AS settingsid FROM mdl_course_modules course_modules INNER JOIN mdl_course course ON course_modules.course = course.id LEFT JOIN mdl_block_ajax_marking settings ON settings.instanceid = course.id AND settings.tablename = 'course' AND settings.userid = '6' WHERE course_modules.course IN ('2','4') AND course_modules.module IN ('1','7','14','20') AND course.visible = 1 ORDER BY course.shortname ASC, name ASC [array ( 0 => '6', 1 => 2, 2 => 4, 3 => '1', 4 => '7', 5 => '14', 6 => '20', )]
Stacktrace:
- line 394 of \lib\dml\moodle_database.php: dml_read_exception thrown * line 252 of \lib\dml\sqlsrv_native_moodle_database.php: call to moodle_database->query_end() * line 368 of \lib\dml\sqlsrv_native_moodle_database.php: call to sqlsrv_native_moodle_database->query_end() * line 773 of \lib\dml\sqlsrv_native_moodle_database.php: call to sqlsrv_native_moodle_database->do_query() * line 807 of \lib\dml\sqlsrv_native_moodle_database.php: call to sqlsrv_native_moodle_database->get_recordset_sql() * line 650 of \blocks\ajax_marking\classes\query_base.class.php: call to sqlsrv_native_moodle_database->get_records_sql() * line 1123 of \blocks\ajax_marking\classes\nodes_builder.class.php: call to block_ajax_marking_query_base->execute() * line 59 of \blocks\ajax_marking\actions\ajax_nodes.php: call to block_ajax_marking_nodes_builder::get_config_nodes()