MDL-36014 cohorts: fix error in SQL query

This commit is contained in:
Marina Glancy 2014-10-09 15:33:49 +08:00
parent 0993f24df0
commit 6fd0b781e1

View File

@ -4522,7 +4522,7 @@ function cohort_get_visible_list($course, $onlyenrolled=true) {
$left JOIN ({cohort_members} cm
JOIN ($esql) u ON u.id = cm.userid) ON cm.cohortid = c.id
WHERE c.contextid $parentsql
GROUP BY c.id, c.name, c.contextid, c.idnumber
GROUP BY c.id, c.name, c.contextid, c.idnumber, c.visible
$having
ORDER BY c.name, c.idnumber, c.visible";