SQLite already compares integer first fields directly during an index seek. We used a Haskell partial evaluator to specialize the comparison after a tie. For a warm four-row range query on a covering index with a payload column, the stock-to-specialized time ratio was 1.0244 (95% paired interval 0.9875–1.0755). An index with exactly two declared columns gave 0.9882 (0.9725–1.0019). All 149,784 direct comparison tests agreed with stock. These measurements establish feasibility, while leaving a whole-query speed advantage unresolved.
