The column status_timeline_relationship.status_id is not indexed so sqlite has no way for a speedy lookup of rows by status_id. Thus it looks up all matching rows from status_timeline_relationship and does index-based lookups in status. Try an index on status_id or on (status_id, timeline_id).

As Simon already mentionend, run ANALYZE before your tests. And building sqlite with SQLITE_ENABLE_STAT3 may also help if you have odd index distributions.

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

Reply via email to