leetcode

Leetcode submissions
git clone git://git.laack.co/leetcode.git
Log | Files | Refs | README

patients-with-a-condition.sql (281B)


      1 --Given a a table with patients and medical records
      2 --return all patients who have a condition which is denoted
      3 --by DIAB1 in the conditions field followed by the condition.
      4 
      5 SELECT * 
      6 FROM Patients
      7 WHERE Patients.conditions 
      8 LIKE '% DIAB1%' OR 
      9 Patients.conditions 
     10 LIKE 'DIAB1%'