Searching for terms that already contain a masking character

If you want to search for a term that contains the "%" character or the "_" character, you must precede the character with a so-called escape character. Then you can identify the escape character using the ESCAPE keyword.

In the following example, the escape character is a "!":

SELECT AUTHOR, TITLE
        FROM DB2EXT.TEXTTAB
        WHERE CONTAINS(COMMENT, 
                    '"100!%" ESCAPE "!"') = 1