SELECT doctor_id, first_name, last_name FROM doctors WHERE doctor_id IN (SELECT DISTINCT attending_doctor_id FROM admissions);
Write your query and click "Run Query" (Ctrl + Enter) to see results and testcase validation.