On Fri, May 25, 2018 at 10:29 AM, x <tam118...@hotmail.com> wrote:

> You could have interrupt checks just before the return of a result row
> yourself by creating a Step fct that  called sqlite3_step and then checked
> for an interrupt. It’s when the sqlite3.c code’s being run interrupt is
> most needed. e.g. if a query has a large result set that needs sorting the
> first sqlite3_step could be a very lengthy operation.
>
> The only way I can see around it is to use “select sum(1) from Tbl” to get
> the count. That uses plenty of VMI’s but is slower.
>
>
I suppose Select count(*) is uninterruptible for some historical reasons.
you can also use Select count(rowid) ... (if the table is not WITHOUT
ROWID), it's interruptible, just checked, at least in v3.23.1. Probably
takes the same time as Select sum(1), but a little bit less cryptic when
reading
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to