Skip to content
Advertisement

Filter SQL Query contain Array

I have a query, to display Profile, one of the column contain Array of languages fluent in.

My question, what i should add to the Query, to Filter query “English”, AND “Arabic” ?

My SQL Query:

Advertisement

Answer

Try:

pm4.meta_value LIKE "%Arabic%" AND pm4.meta_value LIKE "%English%"

You can put it in the WHERE clause or in the JOIN ON. It’s better in the JOIN part.

User contributions licensed under: CC BY-SA
2 People found this is helpful
Advertisement