Closed mudrd8mz closed 4 years ago
It seems to affect other filter options too:
Debug info: ERROR: column reference "id" is ambiguous
LINE 1: ...STS ( SELECT userid FROM m_user_enrolments ) AND id IN ( S...
^
SELECT COUNT(1) FROM m_files f JOIN m_user u on u.id = f.userid WHERE f.filename like '%.mbz' and f.filename <> '.' and f.component <> 'tool_recyclebin' and f.filearea <> 'draft' and EXISTS ( SELECT userid FROM m_user_enrolments ) AND id IN ( SELECT userid FROM m_user_enrolments )
[array (
)]
Error code: dmlreadexception
Stack trace:
line 486 of /lib/dml/moodle_database.php: dml_read_exception thrown
line 329 of /lib/dml/pgsql_native_moodle_database.php: call to moodle_database->query_end()
line 920 of /lib/dml/pgsql_native_moodle_database.php: call to pgsql_native_moodle_database->query_end()
line 1624 of /lib/dml/moodle_database.php: call to pgsql_native_moodle_database->get_records_sql()
line 1697 of /lib/dml/moodle_database.php: call to moodle_database->get_record_sql()
line 1907 of /lib/dml/moodle_database.php: call to moodle_database->get_field_sql()
line 1964 of /lib/tablelib.php: call to moodle_database->count_records_sql()
line 2019 of /lib/tablelib.php: call to table_sql->query_db()
line 120 of /report/allbackups/index.php: call to table_sql->out()
Thanks David - I was planning to remove a bunch of those filters anyway but hadn't noticed they were triggering errors - will tidy that up and update the plugins db next week!
After enabling Course role is "Teacher" in any course from "Miscellaneous" filter setting, I get DB exception on my PostgreSQL test machine: