On Sat, Apr 9, 2011 at 7:06 AM, Richard Hipp <d...@sqlite.org> wrote:

>
>
> On Fri, Apr 8, 2011 at 10:55 AM, Martin Gadbois <mgadb...@gmail.com>wrote:
>
>> Hi there!
>>
>> I noticed a heavy slow-down due to automatic indexes. Look at the
>> following
>> output, where table "events" has 100k entries, and "tags" has ~10 entries:
>>
>
> Thanks for the details in your trouble report.  However, you left out the
> details we need the most, which are (in order):
>
> (1) The complete database scheme
> (2) The content of the sqlite_stat1 and sqlite_stat2
>
> Note that (2) won't exist if you haven't run ANALYZE, which is fine - we
> just need to know that.
>
> --
> D. Richard Hipp
> d...@sqlite.org
>

1)
The schema is as follows:
CREATE TABLE ev_descr ( event_type integer, description text);
CREATE TABLE events(
    timestamp integer,
    event_type integer,
    parameter text,
    source text,
    ap blob,
    ap_name text,
    sc blob,
    sc_name text,
        port text,
        vlan integer,
        sta text,
        vsc text,
        bssid blob,
    user text
    );
CREATE TABLE tags ( event_type integer, tag text);

2)
ANALYZE has not been run.

If ANALYZE is ran, the speed is fast: there are no auto-index.

sqlite> select * from sqlite_stat1;
tags||12
ev_descr||11
events||100000

Again, the database contains test data, so I can provide it to you (maybe
not on the list?). The size is around 7Mb.

PS: I am now a registered sqlite-user.
PPS: thanks for a great product! Much smaller than Berkeley DB and so much
powerful!

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

Reply via email to