高度なサービスを備えたSQLServer2005ExpressEditionを使用しています。フルテキストを有効にして、次のようにカタログを作成しました。
create FullText catalog MyDatabase_FT in path 'mypath' as default
次に、次のようにフルテキストインデックスを作成しました。
create FullText index on Cell (CellName) key index PK_Cell
with CHANGE_TRACKING AUTO
次のクエリを実行しました。
1) select count(*) from Cell where contains (CellName, 'CU*')
2) select count(*) from Cell where CellName like 'CU%'
そして、次の結果が得られました。
1)0
2)24
FullTextインデックスにデータを入力するのに時間がかかる可能性があることを認識しています。しかし、多くの時間(12時間)にもかかわらず、私はまだ結果を得ることができません。次に、ObjectPropertyEx()関数を使用してさらに調査し、以下を実行しました。
declare @id int
select @id = id FROM sys.sysobjects where [Name] = 'Cell'
select 'TableFullTextBackgroundUpdateIndexOn' as 'Property', objectpropertyex(@id, 'TableFullTextBackgroundUpdateIndexOn') as 'Value'
union select 'TableFullTextChangeTrackingOn', objectpropertyex(@id, 'TableFullTextChangeTrackingOn')
union select 'TableFulltextDocsProcessed', objectpropertyex(@id, 'TableFulltextDocsProcessed')
union select 'TableFulltextFailCount', objectpropertyex(@id, 'TableFulltextFailCount')
union select 'TableFulltextItemCount', objectpropertyex(@id, 'TableFulltextItemCount')
union select 'TableFulltextKeyColumn', objectpropertyex(@id, 'TableFulltextKeyColumn')
union select 'TableFulltextPendingChanges', objectpropertyex(@id, 'TableFulltextPendingChanges')
union select 'TableHasActiveFulltextIndex', objectpropertyex(@id, 'TableHasActiveFulltextIndex')
これにより、次の結果が得られました。
TableFullTextBackgroundUpdateIndexOn 1
TableFullTextChangeTrackingOn 1
TableFulltextDocsProcessed 11024
TableFulltextFailCount 0
TableFulltextItemCount 4038
TableFulltextKeyColumn 1
TableFulltextPendingChanges 0
TableHasActiveFulltextIndex 1
次に、次のようにインデックスの新しい完全な母集団を作成しようとしました。
alter fulltext index on Cell start full population
そして、私は次の警告を受け取ります:
Warning: Request to start a full-text index population on table or indexed view 'Cell' is ignored because a population is currently active for this table or indexed view.
私は次のように人口を更新しようとしました:
alter fulltext index on Cell start update population
これにより、「コマンドは正常に完了しました。」というメッセージが返されましたが、全文検索で結果が得られません。
私は何が欠けていますか?全文検索を機能させるには何をする必要がありますか?
ありがとう、エラン