Assume these two tables:
blog
id title keywords
1 Hello hello,world,test
2 Google search, email, security
3 Microsoft clippy, collaboration
category
id keywords
1 test, world, clippy
How do I search for blog rows that have one or more keyword matching a keyword in the category row?
Succinctly: if you want to do that operation, you don’t store your data like that. You normalize your data, and search using the normalized data:
Now you can search easily using simple joins:
It isn’t completely clear what you’d want to see if there were multiple catagories.