I found this thread about the same problem, but the proposed solution doesn't work for me Can I use a variable when using ISABOUT?
My code is fairly simple:
DECLARE @SearchTerm varchar(8000)
set @SearchTerm = 'IC_PARTY'
set @SearchTerm = @SearchTerm + '*'
select
ct1.rank AS NAME_RANK,
t.id,
t.name,
t.text_short,
t.text_long,
t.text_search,
t.searchtype,
t.type,
t.notice
from [CMRUSER].[WK_FULLTEXT_D_UQID] t
left join CONTAINSTABLE([CMRUSER].[WK_FULLTEXT_D_UQID], NAME_ND, N'ISABOUT(' + @SearchTerm + 'WEIGHT(0.1))') ct1
ON t.id = ct1.[KEY]
What I need to do is pass a variable into ISABOUT(), but im getting error "an expression of non-boolean type specified in a context where a condition is expected"
Anybody could advise on how to approach this problem?
I will have 4 same joins as this one. Each for every searched columns and they will also be weighted.