Force Seek는 강제로 인덱스를 태우기(?) 위한 쿼리 힌트다. 예제를 보면 쉽게 알 수 있다. 테스트를 위한 준비를 하자. {{{ use tempdb go set nocount on set statistics io off --drop table force_seek_table create table force_seek_table ( col1 int identity not null, col2 tinyint not null ); go begin tran; declare @i int; set @i = 1; while (@i <= 1000000) begin if (@i <=100000) insert into force_seek_table (col2) values (10); if (@i > 100000 and @i <= 1000000) insert into force_seek_table (col2) values (90); set @i = @i + 1; end commit; go create nonclustered index force_seek_table on force_seek_table (col2); go }}} 다음의 쿼리를 실행해 보자. {{{ select * from force_seek_table where col2 = 10; }}} attachment:ForceSeek/force_seek01.jpg SQL Server 옵티마이저는 풀스캔을 선택했다. Force Seek 힌트를 주면 어떻게 될까? 당연히 Index Seek 할테다. {{{ select * from force_seek_table with (forceseek) where col2 = 10; }}} attachment:ForceSeek/force_seek02.jpg