I need to get the student details who got un-enrolled from course. As I can see user_enrollments or enrol tables do not have un-enrolled student data. Is there a way to do this? Perhaps a sql query?
In reply to Dulitha Rajapaksha
Re: Is there a way to get un-enrolled users from courses?
by Richard Oelmann -
An SQL query that hits up the log tables should be able to give that information. I'll try and have a look over the weekend, but someone may well get there quicker than I'll be able to (and with better sql experience ;) )
In reply to Richard Oelmann
Re: Is there a way to get un-enrolled users from courses?
by Dulitha Rajapaksha -
Thanks a lot Richard. Please post if you find a way to do this
In reply to Dulitha Rajapaksha
Re: Is there a way to get un-enrolled users from courses?
by John Provasnik -
You can through logs within Moodle, or if you do an sql statement, maybe you can look for only logs that contain certain text (simply manually unenroll a test user from a course then look at the logs to see the exact verbiage used)
In reply to John Provasnik
Re: Is there a way to get un-enrolled users from courses?
by Dulitha Rajapaksha -
My log tables were empty. Checked both log and log_queries tables. Running on moodle 3.8
In reply to John Provasnik
Re: Is there a way to get un-enrolled users from courses?
by Dulitha Rajapaksha -
I think I found the correct log table. Its logstore_standard_log and looks like it has everything I needed. Can query with target='user_enrolment' AND action='deleted' Thanks for the support