Task: Text to Code
Input (English): SQL: SELECT dorm_name , Count ( * ) FROM Dorm GROUP BY dorm_name
Feedback: Need to corresponds rows of Has amenity's amenity id .
Output (English): SELECT count(*) ,  T1.dormid FROM dorm AS T1 JOIN has_amenity AS T2 ON T1.dormid  =  T2.dormid WHERE T1.student_capacity  >  100 GROUP BY T1.dormid