Ian Hardingham <i...@omroth.com> wrote:
> Hey Igor, thanks for the reply.
> 
> Is this O(1)?  Or... I guess it's probably low-magnitude O(log n) ?

It's O(n). There's no shortcut to count(*), it walks through and counts all the 
records satisfying the condition. A B-tree doesn't provide a fast way to obtain 
a number of all the elements smaller than a given element.
-- 
Igor Tandetnik

_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to