Hi !

Suppose one database with 4 tables : S1, B1, B2 and B3, where S1 (small 1)
has < 100 records,
and B1, B2, and B3 (big tables) has > 100,000 records each. Them entire
database has +- 400 MegaBytes.
These records are inserted in ramdom order : S1, B1, B1, B1, B3, B2, B1, B1
... etc, so I think
the database will become 'fragmented'.
The SQL : SELECT * FROM S1 will read all 400 megabytes to find the 100
records ?
(and became slow on a older computer) Or the Sqlite is smart enough to seek
only the sectors
of database and find all records as quik as if where only these table on
database ?
Is better to use another database to S1 only ?
I Want to find these records as fast as possible ...
The VACUUM 'desfragment' the database ? (make a copy of all tables in
sequence) ?
If so, After a VACUUM the speed of SELECT * FROM S1 will be faster than
before the vacuum ?
(since all records of S1 will be one right after another and sqlite has not
to scan all 400 Megabytes)

Obs: using version 3.03

Thanks

Rubens Jr.




Reply via email to