I have a specific course that contains 3 Topics/scorm packages and one quiz.
2017 course
- Module 1
- Module 2
- Module 3
- Final Quiz
Is it possible to add a dropdown filter that will contain only the 4 items inside my 2017 course?
I was able to use %%FILTER_CATEGORIES:c.category%% to filter individual courses before, but now all of my courses are contained within the same course. %%FILTER_CATEGORIES:gi.itemname%% does not work.
Here is the code I altered.....
SELECT u.firstname AS 'First' , u.lastname AS 'Last',
gi.itemname AS 'item name',
ROUND(gg.finalgrade,2) AS Grade,
DATE_ADD('1970-01-01', INTERVAL gi.timemodified SECOND) AS Time
FROM prefix_course AS c
JOIN prefix_context AS ctx ON c.id = ctx.instanceid
JOIN prefix_role_assignments AS ra ON ra.contextid = ctx.id
JOIN prefix_user AS u ON u.id = ra.userid
JOIN prefix_grade_grades AS gg ON gg.userid = u.id
JOIN prefix_grade_items AS gi ON gi.id = gg.itemid
JOIN prefix_course_categories AS cc ON cc.id = c.category
WHERE gi.courseid = c.id AND cc.name = '2017 Vehicle Emissions Testing Program Course' AND gi.itemtype = 'mod'
%%FILTER_CATEGORIES:c.category%%
%%FILTER_SYSTEMUSER:ra.userid%%
%%FILTER_SEARCHTEXT:gi.itemname:~%%
%%FILTER_STARTTIME:gg.timemodified:>%% %%FILTER_ENDTIME:gg.timemodified:<%%
ORDER BY firstname