Skip to content

Commit

Permalink
MDL-14160 SQL in get_categories_for_contexts does not work on Oracle.…
Browse files Browse the repository at this point in the history
… Thanks to Adrian Smith and Francois Marier for the fix.
  • Loading branch information
tjhunt committed Sep 2, 2008
1 parent 5ca1863 commit 630a3dc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/questionlib.php
Original file line number Diff line number Diff line change
Expand Up @@ -2132,7 +2132,7 @@ function question_make_default_categories($contexts) {
function get_categories_for_contexts($contexts, $sortorder = 'parent, sortorder, name ASC') {
global $DB;
return $DB->get_records_sql("
SELECT *, (SELECT count(1) FROM {question} q
SELECT c.*, (SELECT count(1) FROM {question} q
WHERE c.id = q.category AND q.hidden='0' AND q.parent='0') AS questioncount
FROM {question_categories} c
WHERE c.contextid IN ($contexts)
Expand Down

0 comments on commit 630a3dc

Please sign in to comment.