How many students registered for courses?
select count(*) from student_course_registrations
Of them, how many did not attend course 301?
select count(*) from student_course_registrations where student_id not in (select student_id from student_course_attendance where course_id = 301)
How many did not even attend any course?
select count(*) from student_course_registrations where student_id not in (select student_id from student_course_attendance)
Give all the info instead.
select * from student_course_registrations where student_id not in (select student_id from student_course_attendance)