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

Intermittent error from the quiz reports on MySQL because of subtracting two unsigned columns

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.9.11
    • Fix Version/s: 1.9.12
    • Component/s: Quiz
    • Environment:
      mysql 5.5.9, moodle 1.9.11+
    • Database:
      MySQL
    • Testing Instructions:
      Hide

      You need a quiz with some student attempts on an 1.9.x install using MySQL > 5.5.5. Make sure you can go to the quiz overview report without errors, and that the durations are displayed correctly.

      It would be good to also test an install using the minimum version of MySQL that Moodle 1.9 is meant to support.

      Show
      You need a quiz with some student attempts on an 1.9.x install using MySQL > 5.5.5. Make sure you can go to the quiz overview report without errors, and that the durations are displayed correctly. It would be good to also test an install using the minimum version of MySQL that Moodle 1.9 is meant to support.
    • Affected Branches:
      MOODLE_19_STABLE
    • Fixed Branches:
      MOODLE_19_STABLE
    • Pull from Repository:

      Description

      I am using mysql 5.5.9. I found that same issue was discussed
      at http://tracker.moodle.org/browse/MDL-26416, but for moodle 1.9.11+.
      The solution seems to be posted at https://github.com/moodle/moodle/blob/master/mod/quiz/report/overview/report.php#L210.

      I wonder the patch will be available for moodle 1.9.11+ soon.

      Thanks.

        Gliffy Diagrams

          Issue Links

            Activity

            Hide
            paaskynen Paul Nijbakker added a comment -

            Ah, I found it at last. I knew there had to be an entry in the tracker for this. We experience the same problem (which according to Tim occurs with all MySql versions since 5.5.5 (we have 5.5.11). We hope this issue can be solved in Moodle 1.9.12 along with the similar issue in the assignment module.

            Show
            paaskynen Paul Nijbakker added a comment - Ah, I found it at last. I knew there had to be an entry in the tracker for this. We experience the same problem (which according to Tim occurs with all MySql versions since 5.5.5 (we have 5.5.11). We hope this issue can be solved in Moodle 1.9.12 along with the similar issue in the assignment module.
            Hide
            timhunt Tim Hunt added a comment -

            It is basically the same fix as before: https://github.com/timhunt/moodle/commit/71ec5d19df4f506ca810cd55e25ebca4c5b94962

            Are you in a position where you can test that change? It would be nice to have independent confirmation before I forward this for integration.

            Show
            timhunt Tim Hunt added a comment - It is basically the same fix as before: https://github.com/timhunt/moodle/commit/71ec5d19df4f506ca810cd55e25ebca4c5b94962 Are you in a position where you can test that change? It would be nice to have independent confirmation before I forward this for integration.
            Hide
            timhunt Tim Hunt added a comment -

            Just getting the workflow into the right state.

            Show
            timhunt Tim Hunt added a comment - Just getting the workflow into the right state.
            Hide
            paaskynen Paul Nijbakker added a comment -

            I will try it out.

            Show
            paaskynen Paul Nijbakker added a comment - I will try it out.
            Hide
            paaskynen Paul Nijbakker added a comment -

            Yup, it works. Big thanks Tim and have a nice labour day weekend!

            P.S. Will this fix make it into 1.9.12?

            Show
            paaskynen Paul Nijbakker added a comment - Yup, it works. Big thanks Tim and have a nice labour day weekend! P.S. Will this fix make it into 1.9.12?
            Hide
            timhunt Tim Hunt added a comment -

            Should get in. Thanks for your testing.

            Show
            timhunt Tim Hunt added a comment - Should get in. Thanks for your testing.
            Hide
            stronk7 Eloy Lafuente (stronk7) added a comment -

            Integrated, thanks!

            Show
            stronk7 Eloy Lafuente (stronk7) added a comment - Integrated, thanks!
            Hide
            mudrd8mz David Mudrak added a comment -

            Test passed on MySQL 4.1.22 with the attempt end time set manually 60 secs before the start time. The reported attempt time is 1 minute. Testing at MySQL 5.5.10 now...

            Show
            mudrd8mz David Mudrak added a comment - Test passed on MySQL 4.1.22 with the attempt end time set manually 60 secs before the start time. The reported attempt time is 1 minute. Testing at MySQL 5.5.10 now...
            Hide
            mudrd8mz David Mudrak added a comment -

            Done. I was able to reproduce the bug and see it is fixed in the integration repository.

            Show
            mudrd8mz David Mudrak added a comment - Done. I was able to reproduce the bug and see it is fixed in the integration repository.
            Hide
            stronk7 Eloy Lafuente (stronk7) added a comment -

            Closing as fixed. Many thanks!

            Show
            stronk7 Eloy Lafuente (stronk7) added a comment - Closing as fixed. Many thanks!
            Hide
            mikidream miki Alliel added a comment -

            Thanks Tim - this worked to me too .
            it fixed me this bug:
            '(`BIGINT UNSIGNED value is out of range in '(`moodle`.`qa`.`timefinish` - `moodle`.`qa.`timestart SELECT CONCAT (u.id,'#', IFNULL (qa.attampt, 0)) AS uniqueid,(CASE WHEN qa.sumgrades = ….

            Thanks!

            Show
            mikidream miki Alliel added a comment - Thanks Tim - this worked to me too . it fixed me this bug: '(`BIGINT UNSIGNED value is out of range in '(`moodle`.`qa`.`timefinish` - `moodle`.`qa.`timestart SELECT CONCAT (u.id,'#', IFNULL (qa.attampt, 0)) AS uniqueid,(CASE WHEN qa.sumgrades = …. Thanks!

              People

              • Votes:
                1 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  10/May/11