I have this array of strings:
array = [ "nike air", "nike steam","nike softy" ,"nike strength",
"smooth sleeper","adidas air","addidas jogar","adidas softy","adidas heels"]
I want to extract strings from this as SQL like query.
E.g if user enter word "nike". Then 4 strings should be return as result
"nike air", "nike steam","nike softy" ,"nike strength"
E.g if user enter word "adidas". Then 4 strings should be return as result
"adidas air","addidas jogar","adidas softy","adidas heels"
Is it possible?
LIKEpredicate, which allows you to pretty much do this but at the database layer. It might offer you a more flexible solution.