Permalink
Browse files

MDL-26338 fix mixed types in quiz reports SQL. This was breaking Oracle

  • Loading branch information...
1 parent f7d843d commit dc3826eed73a677a53b2f6de6d7e8a8886cf60aa @timhunt timhunt committed Feb 9, 2011
Showing with 2 additions and 2 deletions.
  1. +1 −1 mod/quiz/report/overview/report.php
  2. +1 −1 mod/quiz/report/responses/report.php
@@ -202,7 +202,7 @@ function display($quiz, $cm, $course) {
if (!$nostudents || ($attemptsmode == QUIZ_REPORT_ATTEMPTS_ALL)) {
// Construct the SQL
- $fields = $DB->sql_concat('u.id', '\'#\'', 'COALESCE(qa.attempt, \'0\')').' AS uniqueid, ';
+ $fields = $DB->sql_concat('u.id', '\'#\'', 'COALESCE(qa.attempt, 0)').' AS uniqueid, ';
if ($qmsubselect) {
$fields .=
"(CASE " .
@@ -185,7 +185,7 @@ function display($quiz, $cm, $course) {
$hasfeedback = quiz_has_feedback($quiz);
// Construct the SQL
- $fields = $DB->sql_concat('u.id', '\'#\'', 'COALESCE(qa.attempt, \'0\')').' AS concattedid, ';
+ $fields = $DB->sql_concat('u.id', '\'#\'', 'COALESCE(qa.attempt, 0)').' AS concattedid, ';
if ($qmsubselect) {
$fields .=
"(CASE " .

0 comments on commit dc3826e

Please sign in to comment.