Find Repeat Admissions With the Same Diagnosis

Postgres Engine
Database Schema
Question (#30)
Display the patients (patient_id, diagnosis) who were admitted more than once with the same diagnosis. Sort the list by patient_id ascending. In cases where the patient_id is the same, sort by the diagnosis in alphabetical order.
Expected Output
Query Editor
User Output Ready
Execute a query or press Ctrl+Enter to view results...
Databases & Questions
Hint
Group by the pair patient and diagnosis, then keep the groups that are larger than one.
Official Solutions
Select a solution...