Lets say we have a table Column with value "This forumn is intended for anyone who wants to use the Structured Query Language (SQL) to access a database".
If I say
table.column like '%cc%' even it is embedded with in the word access it results true.
How should I rephrase LIKE phrase so that it will return false if input parameter is "cc" and true if input parameter is "access"(yes it's something like word matching).
If we can't get the result with LIKE then do we have any function in DB2 as I want to avoid OR/AND.
What you want to do is to look for the token (word) "cc" and not for the substring "cc" in a string.
That means that you should use table.column like '% cc %' (with spaces before and after cc). But if cc could start or end the string preceded or ended with 'nothing' (i.e. the first word of a string or the last word), ',', or '.' or ... things get really complicated. In that case the best way to handle this is by using regular expressions.