If the array includes these inputs in the records:
Brown bear
Brown cat
Tin can
Empty can
is there a way to SELECT results which CONTAIN words like “brown” and “can”?
I would like to have an easy way of getting information from a database without having to type in the identical match record. Say a database of recording artists records and you only want results for Rolling Stones and Kylie Minogue of which there would be 100’s of songs. You could type in SELECT which contains rolling stones and kylie minogue???
SELECT * FROM your_table WHERE column_name LIKE '%Brown%' or column_name LIKE '%can%'
This is assuming that you are selecting from sql database, if you have XML or an array of strings you probably want to use regular expression instead(which is out of my scope of knowledge in terms of syntax). You need to replace your_table and column_name by the appropriate table and column name in your application though.
Yeah I think so, its not too much typing though unless you are trying to match more than 3 values at the same time. You can always give a try on using comma delimiter, cant guarantee you get the same result but if that works for you please let me know.