SQL Interview Questions – Patients with a Condition

Spread the love

Problem Description –

Write an SQL query to report the patient_id, patient_name all conditions of patients who have Type I Diabetes. Type I Diabetes always starts with DIAB1 prefix

Return the result table in any order.

The query result format is in the following example.

Problem Link – Patients with a condition

Difficulty Level – Easy

Solution –

SELECT * FROM Patients
WHERE conditions LIKE '% DIAB1%'
OR conditions LIKE 'DIAB1%'

Rating: 1 out of 5.

Leave a Reply