Alex I Alex I - 1 year ago 61
SQL Question

How do I find column which columns have all numbers in an array

I am using PHP

I have an SQL Table that looks like so:
SQL Table:

I am trying to retrieve all rows which contain "9" in the "FAMILY" Column
How would I do so?
Note: The numbers are separated by hyphens "-"

Answer Source

Please try this query:

select * from table_name where concat('-',FAMILY,'-') like '%-9-%';
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download