1

我怎样才能启用Full Text Search in SQL Server 2014.

最近几个小时我一直在网上搜索,一些关于 SQL Server 2012 的帖子说它在安装过程中的功能中,但我去了那里,我没有启用它的选项。我确定它肯定已安装但未启用运行以下查询:

SELECT SERVERPROPERTY('IsFullTextInstalled') AS IsFullTextInstalled,
       DatabaseProperty(DB_NAME(DB_ID()), 'IsFulltextEnabled') AS IsFulltextEnabled

哪个返回:

IsFullTextInstalled=1
IsFullTextEnabled=0

谢谢!

4

1 回答 1

0

您已经完成了实例的“已安装”部分。我相信“启用”与在实例中为特定数据库建立全文搜索有关,例如,使用 T-SQL 和 AdventureWorks:

--create a full-text catalog
USE AdventureWorks;  
GO  
CREATE FULLTEXT CATALOG AdvWksDocFTCat;  

-- Ensure the table (Document in this example) has a unique, single-column, non-nullable index
CREATE UNIQUE INDEX ui_ukDoc ON Production.Document(DocumentID);  

-- Create a full-text index on the Document table
CREATE FULLTEXT INDEX ON Production.Document  
(  
    Document                         --Full-text index column name   
    TYPE COLUMN FileExtension    --Name of column that contains file type information
    Language 2057                 --2057 is the LCID for British English  
)  
KEY INDEX ui_ukDoc ON AdvWksDocFTCat --Unique index  
WITH CHANGE_TRACKING AUTO            --Population type;  
GO  

有关此示例的更多详细信息,请参阅 Microsoft 文章:https ://docs.microsoft.com/en-us/sql/relational-databases/search/get-started-with-full-text-search

更通用的教程位于:https ://docs.microsoft.com/en-us/sql/relational-databases/search/create-and-manage-full-text-indexes

于 2018-02-20T16:54:15.367 回答