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

Blocks/search.php invalid column name in query.

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: 2.0
    • Fix Version/s: 2.0
    • Component/s: Blocks
    • Labels:
      None
    • Affected Branches:
      MOODLE_20_STABLE
    • Fixed Branches:
      MOODLE_20_STABLE

      Description

      admin > Plugins > Blocks > Manage Blocks - view list of places a particular block is being used, get this error:

      Debug info: Unknown column 'bi.contextid' in 'on clause'

      SELECT * FROM mdl_course WHERE id IN (
      SELECT DISTINCT ctx.instanceid
      FROM mdl_context ctx
      JOIN mdl_block_instances bi ON bi.contextid = ctx.id
      WHERE ctx.contextlevel = 50 AND bi.blockname = ?)
      [array (
      0 => 'completionstatus',
      )]
      Stack trace:

      • line 378 of /lib/dml/moodle_database.php: dml_read_exception thrown
      • line 591 of /lib/dml/mysqli_native_moodle_database.php: call to moodle_database->query_end()
      • line 140 of /course/search.php: call to mysqli_native_moodle_database->get_recordset_sql()

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  24/Nov/10