我想在一个字段中搜索几个单词
我的代码
string[] tags = key.Split(' ');
foreach (var tag in tags)
{
result = result.Where(EF.Functions.FreeText(n.Article, tag));
}
此查询在sqlserver上运行(通过 AND )
(((FREETEXT([n].[Article], @__tag_1)) AND (((FREETEXT([n].[Article], @__tag_2)) AND (((FREETEXT([n].[Article], @__tag_3))
但是我想要此查询(通过 OR )
(((FREETEXT([n].[Article], @__tag_1)) OR (((FREETEXT([n].[Article], @__tag_2)) OR (((FREETEXT([n].[Article], @__tag_3))
如何修复
谢谢