I have a table name company
Company | category_id
NEC | cg17,cg19,cg23
Huawei | cg55,cg17,cg25
Which I query like this:
select * from company
where category_id RLIKE '^cg17,cg19'
with result:
Company | category_id
NEC | cg17,cg19,cg23
but when I query like this:
select * from company
where category_id RLIKE '^cg17,cg23'
I get no rows, but I want company "NEC", because NEC has category_id "cg17,cg19,cg23"
How to fix this?