I have index on a column, let's say ID
(bigint). If I have a query with something like this:
SELECT *
FROM table
WHERE id = 12345
...it will use index. But when I'm using query like...
SELECT *
FROM table
WHERE id >= 12345
AND id <= 12366
It use sequential scan, which is very slow. Can I force using the ID index?