Question: Given tables students, difficulty, contests, and submissions with the following schemas. students Column Type student_id INTEGER name TEXT divisions Column Type division_id INTEGER score INTEGER

Given tables students, difficulty, contests, and submissions with the following schemas. students Column Type student_id INTEGER name TEXT divisions Column Type division_id INTEGER score INTEGER contests Column Type contest_id INTEGER author_id INTEGER division_id INTEGER submissions Column Type submission_id INTEGER student_id INTEGER contest_id INTEGER score INTEGER The submissions table contains a submission (submission_id) made by a student (student id) to a contest (contest_id) and the score of the submission (score). A student can make multiple submissions to the same contest and receive multiple scores. The contests table contains the author (author id) of their contest submission contest_id) that belongs to a certain division (division_id). The divisions table contains the max score (score) of each contest that belongs to a certain division (division_id). Write a SQL query to retrieve the student id and name of the students who received max scores in more than one contest. Order the results by first the total number contests in which the student earned a full score, and then the student_id (in ascending order)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
