mirror of
https://github.com/moodle/moodle.git
synced 2025-03-24 09:30:17 +01:00
MDL-56516 tool_usertours: Adjust tour query for MySQL
This commit is contained in:
parent
1093e43bda
commit
67b49f27a4
@ -61,10 +61,8 @@ class cache {
|
||||
$sql = <<<EOF
|
||||
SELECT t.*
|
||||
FROM {tool_usertours_tours} t
|
||||
INNER JOIN {tool_usertours_steps} s ON s.tourid = t.id
|
||||
WHERE t.enabled = 1
|
||||
GROUP BY t.id
|
||||
HAVING COUNT(s.id) > 0
|
||||
AND t.id IN (SELECT s.tourid FROM {tool_usertours_steps} s GROUP BY s.tourid)
|
||||
ORDER BY t.sortorder ASC
|
||||
EOF;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user