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

Upgrading Quiz structure fails with sql error

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: 2.7
    • Fix Version/s: 2.7
    • Component/s: Quiz
    • Labels:

      Description

      While testing MDLQA-7111,

      1. I used test data set (Please contact me and I will see how I can share the dataset)
      2. upgraded the site to 2.6 integration.
      3. Upgraded to master integration and it failed at Upgrading quiz structure - 1018/6733 with

        Debug info: ERROR: invalid input syntax for integer: ""
        SELECT defaultmark FROM mdl_question WHERE id = $1
        [array (
        0 => '',
        )]
        Error code: dmlreadexception
        Stack trace:
        line 443 of /lib/dml/moodle_database.php: dml_read_exception thrown
        line 244 of /lib/dml/pgsql_native_moodle_database.php: call to moodle_database->query_end()
        line 764 of /lib/dml/pgsql_native_moodle_database.php: call to pgsql_native_moodle_database->query_end()
        line 1476 of /lib/dml/moodle_database.php: call to pgsql_native_moodle_database->get_records_sql()
        line 1549 of /lib/dml/moodle_database.php: call to moodle_database->get_record_sql()
        line 1530 of /lib/dml/moodle_database.php: call to moodle_database->get_field_sql()
        line 1509 of /lib/dml/moodle_database.php: call to moodle_database->get_field_select()
        line 613 of /mod/quiz/db/upgrade.php: call to moodle_database->get_field()
        line 697 of /lib/upgradelib.php: call to xmldb_quiz_upgrade()
        line 420 of /lib/upgradelib.php: call to upgrade_plugins_modules()
        line 1615 of /lib/upgradelib.php: call to upgrade_plugins()
        line 432 of /admin/index.php: call to upgrade_noncore()
        

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              timhunt Tim Hunt
              Reporter:
              rajeshtaneja Rajesh Taneja
              Peer reviewer:
              Rajesh Taneja
              Integrator:
              Damyon Wiese
              Tester:
              Rajesh Taneja
              Participants:
              Component watchers:
              Tim Hunt, Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Fix Release Date:
                12/May/14