SQL Query to count number of courses using the gradebook

SQL Query to count number of courses using the gradebook

by Eric Katchan -
Number of replies: 0
Hello, I was wondering if anyone knew a query where I could determine the number of courses in moodle using the gradebook? 

I am wonder if the following would provide an accurate count.

select count ( distinct courseid ) from mdl_grade_settings;