On Thu, Jun 6, 2013 at 11:26 AM, Gabriel Corneanu <[email protected]
> wrote:

>
> 2. Is there NO WAY to quickly get the row count WITHOUT full scan if I
> only have the auto primary key??
>

The b-tree structures in the SQLite file format do not store the row count,
as that slows down writes (since the row count would have to be updated
with each insert or delete).

If you want fast access to a row count, store it in a separate table and
keep it up-to-date using triggers.

-- 
D. Richard Hipp
[email protected]
_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to