Logic dẫn xuất chi phí đầy đủ là phức tạp, nhưng đối với trường hợp tương đối đơn giản trong câu hỏi:
Đầu vào
- Số lần toán tử được thực thi 
 Đây là Số lần thực hiện ước tính : 504
 
- Cardinality (tổng số hàng) trong chỉ mục 
 các TableCardinality tài sản của Index Seek điều hành cung cấp cho này: 113.443
 
- Số lượng trang dữ liệu trong chỉ mục: 201
 Số này có thể được lấy theo nhiều cách, ví dụ từ- sys.allocation_units:
 - SELECT 
    AU.data_pages
FROM sys.allocation_units AS AU
JOIN sys.partitions AS P
    ON P.hobt_id = AU.container_id
WHERE
    AU.[type_desc] = N'IN_ROW_DATA'
    AND P.[object_id] = OBJECT_ID(N'Production.TransactionHistory', N'U')
    AND P.index_id = 
        INDEXPROPERTY(P.[object_id], N'IX_TransactionHistory_ProductID', 'IndexID');
 
- Mật độ (1 / giá trị riêng biệt ) của chỉ số: 0,002267574
 Điều này có sẵn trong vectơ mật độ của thống kê chỉ số:
 - DBCC SHOW_STATISTICS 
(
    N'Production.TransactionHistory', 
    N'IX_TransactionHistory_ProductID'
) 
WITH DENSITY_VECTOR;
  
 
Tính toán
-- Input numbers
DECLARE
    @Executions float = 504,
    @Density float = 0.002267574,
    @IndexDataPages float = 201,
    @Cardinality float = 113443;
-- SQL Server cost model constants
DECLARE
    @SeqIO float = 0.000740740740741,
    @RandomIO float = 0.003125,
    @CPUbase float = 0.000157,
    @CPUrow float = 0.0000011;
-- Computation
DECLARE
    @IndexPages float = CEILING(@IndexDataPages * @Density),
    @Rows float = @Cardinality * @Density,
    @Rebinds float = @Executions - 1e0;
DECLARE
    @CPU float = @CPUbase + (@Rows * @CPUrow),
    @IO float = @RandomIO + (@SeqIO * (@IndexPages - 1e0)),
    -- sample with replacement
    @PSWR float = @IndexDataPages * (1e0 - POWER(1e0 - (1e0 / @IndexDataPages), @Rebinds));
-- Cost components (no rewinds)
DECLARE
    @InitialCost float = @RandomIO + @CPUbase + @CPUrow,
    @RebindCPU float = @Rebinds * (1e0 * @CPUbase + @CPUrow),
    @RebindIO float = (1e0 / @Rows) * ((@PSWR - 1e0) * @IO);
-- Result
SELECT 
    OpCost = @InitialCost + @RebindCPU + @RebindIO;
db <>
