SQL query to get course id based on the module topic, activities and content inside it

Re: SQL query to get course id based on the module topic, activities and content inside it

Rick Jerz發表於
Number of replies: 0
Particularly helpful Moodlers的相片 Testers的相片

A lot depends upon what you are looking for.

If you look at the tables in your Moodle database, you will see that a lot of them (oh, maybe 10 or so, see graphic) start with "prefix_course."  You should explore these tables to see which ones contain the words that you are interested in.

In SQL, pattern matching can be done with the "like" comparison operator.  For example:

SELECT * FROM mdl_course

where fullname like "%MBA%"