Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-25053

SQL error shown when trying to report on participation in an activity

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.9.10, 2.0
    • 1.9.11, 2.0
    • Course
    • None
    • postgres 8.3
    • PostgreSQL
    • MOODLE_19_STABLE, MOODLE_20_STABLE
    • MOODLE_19_STABLE, MOODLE_20_STABLE
    • Easy

    Description

      Throws an SQL error due to ill formed SQL

      See line 200 approx of /course/report/participation/index.php

      SELECT userid, COUNT(action) actioncount FROM

      {log} WHERE cmid = :instanceid AND time > :timefrom AND $actionsql GROUP BY userid

      should read as follows for Postgres

      SELECT userid, COUNT(action) AS actioncount FROM {log}

      WHERE cmid = :instanceid AND time > :timefrom AND $actionsql GROUP BY userid

      Attachments

        Activity

          People

            skodak Petr Skoda
            alanfez Alan Peter Carter
            Nobody Nobody
            Amaia Anabitarte, Carlos Escobedo, Ferran Recio, Ilya Tregubov, Laurent David, Sara Arjona (@sarjona)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              24/Nov/10