方法一:没有正则表达式
SELECT patient_id, patient_name, conditions
FROM Patients
WHERE conditions LIKE 'DIAB1%' OR conditions LIKE '% DIAB1%';
方法二:有正则表达式
select *
from Patients
where conditions REGEXP '^DIAB1|\\sDIAB1';
方法一:没有正则表达式
SELECT patient_id, patient_name, conditions
FROM Patients
WHERE conditions LIKE 'DIAB1%' OR conditions LIKE '% DIAB1%';
方法二:有正则表达式
select *
from Patients
where conditions REGEXP '^DIAB1|\\sDIAB1';