我有查询: var query = DataContext.Fotos.Where(x = x.Pesquisa.Contais("myTerm") 生成的SQL是: SELECT … FROM Fotos AS [Extent1] WHERE [Extent1].[Pesquisa] LIKE N’%mytem%’ 但是我需要使用: SELECT … FROM Fotos AS [Ext
var query = DataContext.Fotos.Where(x => x.Pesquisa.Contais("myTerm")
生成的SQL是:
SELECT
…
FROM Fotos AS [Extent1]
WHERE [Extent1].[Pesquisa] LIKE N’%mytem%’
但是我需要使用:
SELECT
…
FROM Fotos AS [Extent1]
WHERE CONTAINS ([Extent1].[Pesquisa], ‘my term’)
如何使用实体框架6执行全文搜索?
似乎实体框架6不支持全文搜索,但是有一个拦截器的解决方法.http://www.entityframework.info/Home/FullTextSearch