SQLite Forum

Query planner fails to use obvious index
> explain query plan

> select min(id) from test where key_id >= 1

> returns "SEARCH TABLE test", which does not use the index (and is very slow in my real world case), while the following "workaround" query

Because 99.9% of the table has to be read, to know the minimal value of `id`, the choice is made to read the complete table.

Nothing wrong with that.