1670. Patients With a Condition
My accepted SQL solution to LeetCode problem 1670, Patients With a Condition, running in 373ms.
- Difficulty: Easy
- SQL
- Runtime 373ms
- Memory 0.0B
- Updated
Read the problem on LeetCode View on GitHub
The problem statement is LeetCode’s and stays on their site. What follows is my accepted solution.
SQL
Accepted on LeetCode — runtime 373ms, memory 0.0B, accepted 2025-12-29.
SELECT patient_id, patient_name, conditions
FROM Patients
WHERE conditions LIKE 'DIAB1%' OR conditions LIKE '% DIAB1%'