SELECT T1.subject_id, T2.subject_name, COUNT(*) FROM Courses AS T1 JOIN Subjects AS T2 ON T1.subject_id = T2.subject_id GROUP BY T1.subject_id ORDER BY COUNT(*)
Temukan ID subjek, nama subjek dan jumlah kursus yang sesuai untuk setiap subjek, dan mengurutkan berdasarkan jumlah kursus dalam urutan naik.
CREATE TABLE Courses (subject_id VARCHAR); CREATE TABLE Subjects (subject_name VARCHAR, subject_id VARCHAR)