Attempting to create a new problem section on a site running on PostgreSQL end with fatal error:
Debug info: ERROR: column "u.id" must appear in the GROUP BY clause or be used in an aggregate function
LINE 1: SELECT COUNT(u.id) AS nbuser, u.id, u.firstname, u.lastname,...
^
SELECT COUNT(u.id) AS nbuser, u.id, u.firstname, u.lastname, u.email, CONCAT(u.firstname,u.lastname) AS fullname FROM mdl_user u, mdl_groups_members gm, mdl_groupings_groups gg WHERE u.id = gm.userid AND gm.groupid = gg.groupid AND gg.groupingid = 1 AND u.id = 10
[array (
)]
Error code: dmlreadexception
×Stack trace:
line 474 of /lib/dml/moodle_database.php: dml_read_exception thrown
line 242 of /lib/dml/pgsql_native_moodle_database.php: call to moodle_database->query_end()
line 776 of /lib/dml/pgsql_native_moodle_database.php: call to pgsql_native_moodle_database->query_end()
line 1527 of /lib/dml/moodle_database.php: call to pgsql_native_moodle_database->get_records_sql()
line 152 of /local/problemsection/selector.php: call to moodle_database->get_record_sql()
line 181 of /local/problemsection/selector.php: call to local_problemsection_nonmembers_selector->find_users()
line 248 of /local/problemsection/groups.php: call to local_problemsection_nonmembers_selector->display()
Attempting to create a new problem section on a site running on PostgreSQL end with fatal error: