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

Grader report generates SQL error on Oracle

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 2.2.1
    • Fix Version/s: 2.2.4
    • Component/s: Gradebook
    • Labels:
    • Database:
      Oracle
    • Testing Instructions:
      Hide

      This requires Oracle to really test it properly. Testing in any other DB will at least check nothing was broken.

      Check that the site setting "showuseridentity" has email address ticked.

      Go to the grader report and check that no warnings or errors are displayed.

      Show
      This requires Oracle to really test it properly. Testing in any other DB will at least check nothing was broken. Check that the site setting "showuseridentity" has email address ticked. Go to the grader report and check that no warnings or errors are displayed.
    • Affected Branches:
      MOODLE_22_STABLE
    • Fixed Branches:
      MOODLE_22_STABLE
    • Pull Master Branch:
      MDL-31804_ambiguous_sql

      Description

      With an Oracle database, when the 'Show user identity' setting (User policies) is set to 'Email address' and a teacher views the Grader report, an SQL error is thrown when the 'email' field is included twice:

      Debug info: ORA-00918: column ambiguously defined
      SELECT *
      FROM (SELECT u.id,u.picture,u.firstname,u.lastname,u.imagealt,u.email, email
      FROM z_user u
      JOIN (SELECT DISTINCT eu1_u.id
      ...

      It seems to have been introduced in MDL-26647. Patch to come shortly.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              andyjdavis Andrew Davis
              Reporter:
              jonof Jonathon Fowler
              Peer reviewer:
              Sam Marshall
              Integrator:
              Dan Poltawski
              Tester:
              Jason Fowler
              Participants:
              Component watchers:
              Adrian Greeve, Jake Dallimore, Mathew May, Mihail Geshoski, Peter Dias
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Fix Release Date:
                9/Jul/12