Moodle

sql error on role override page

Details

  • Type: Sub-task Sub-task
  • Status: Closed Closed
  • Priority: Minor Minor
  • Resolution: Fixed
  • Affects Version/s: 1.9
  • Fix Version/s: 1.9
  • Component/s: Roles / Access
  • Labels:
    None
  • Affected Branches:
    MOODLE_19_STABLE
  • Fixed Branches:
    MOODLE_19_STABLE

Description

Got this error after update.

Notice: Trying to get property of non-object in /var/www/19perf/moodle-r2/lib/accesslib.php on line 3389

Notice: Trying to get property of non-object in /var/www/19perf/moodle-r2/lib/accesslib.php on line 3347
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') AND rc.roleid = 3 AND rc.contextid = c.id ' at line 4

SELECT rc.* FROM mdl_role_capabilities rc, mdl_context c WHERE rc.contextid in () AND rc.roleid = 3 AND rc.contextid = c.id ORDER BY c.contextlevel DESC, rc.capability DESC

  • line 677 of lib/dmllib.php: call to debugging()
  • line 918 of lib/dmllib.php: call to get_recordset_sql()
  • line 3367 of lib/accesslib.php: call to get_records_sql()
  • line 175 of admin/roles/override.php: call to role_context_capabilities()

Activity

Hide
Martín Langhoff added a comment -

Not a lot of detail on what you were trying to do... But I'll hazard a few guesses.

I would say that it can only happen if you have contexts with no path, which isn't normal. So I want to fix the missing path...

  • Can you check what contexts you have with no path?
  • does running build_context_path() help fix it?
Show
Martín Langhoff added a comment - Not a lot of detail on what you were trying to do... But I'll hazard a few guesses. I would say that it can only happen if you have contexts with no path, which isn't normal. So I want to fix the missing path...
  • Can you check what contexts you have with no path?
  • does running build_context_path() help fix it?
Hide
Yu Zhang added a comment -

This is not there anymore... closing

Show
Yu Zhang added a comment - This is not there anymore... closing

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: