mirror of
https://github.com/moodle/moodle.git
synced 2025-01-19 06:18:28 +01:00
MDL-34372: Fix query in backup_cron_helper so it works on Postgres 8.3
Amended by stronk7@moodle.org to use uppercase SQL keywords.
This commit is contained in:
parent
821aac54b4
commit
4cb18cb080
@ -255,7 +255,7 @@ abstract class backup_cron_automated_helper {
|
|||||||
self::BACKUP_STATUS_SKIPPED => 0,
|
self::BACKUP_STATUS_SKIPPED => 0,
|
||||||
);
|
);
|
||||||
|
|
||||||
$statuses = $DB->get_records_sql('SELECT DISTINCT bc.laststatus, COUNT(bc.courseid) statuscount FROM {backup_courses} bc GROUP BY bc.laststatus');
|
$statuses = $DB->get_records_sql('SELECT DISTINCT bc.laststatus, COUNT(bc.courseid) AS statuscount FROM {backup_courses} bc GROUP BY bc.laststatus');
|
||||||
|
|
||||||
foreach ($statuses as $status) {
|
foreach ($statuses as $status) {
|
||||||
if (empty($status->statuscount)) {
|
if (empty($status->statuscount)) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user