In SQL, if you want to perform a SELECT with a wildcard, you'd use:
SELECT * FROM table_name WHERE field_name LIKE '%value%'
If you wanted to use an array of possible values, you'd use:
SELECT * FROM table_name WHERE field_name IN ('one', 'two', 'three')
But, what would you do if you wanted to use both wildcards AND an array?
Kind of like:
SELECT * FROM table_name WHERE field_name LIKE IN ('%one', '_two', 'three[abv]')
SELECT *
FROM table_name
WHERE field_name LIKE '%one'
OR field_name LIKE '_two'
OR field_name LIKE 'three[abv]'
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With