Hi
I have a free text index set up on a column in my table. I need to use a SUBSTRING inside the contains but get the following error:
This is an exmaple of the clause:
If I replace the SUBSTRING with a fixed string ('abcd') it works fine.
Are we not able to use functions inside the CONTAINS statement? Or have I done something wrong?
Cheers
Rob
I have a free text index set up on a column in my table. I need to use a SUBSTRING inside the contains but get the following error:
Code:
Msg 102, Level 15, State 1, Line 15
Incorrect syntax near 'SUBSTRING'.
This is an exmaple of the clause:
Code:
AND NOT CONTAINS([mytable].[mycol], SUBSTRING('abcdefghijk', 2, 3))
If I replace the SUBSTRING with a fixed string ('abcd') it works fine.
Are we not able to use functions inside the CONTAINS statement? Or have I done something wrong?
Cheers

Rob