On Thu, Mar 28, 2013 at 8:35 AM, Niall O'Reilly <niall.orei...@ucd.ie> wrote:
>
> On 28 Mar 2013, at 12:09, Jeff Archer wrote:
>
>> But my most basic question remains.  Why is single transaction faster
>> than PRAGMA journal_mode = off?
>>
>> Seems to me that with no journal there should only be single set of
>> writes to the actual db and that journaling would double the number of
>> writes because data has to be written to journal file as well.
>>
>> 2.5 sec with journal
>> 5.5 sec without journal   <= seems like this sould be the smaller number
>
>         Your base-line for comparison is the case of multiple transactions
>         with journalling.
>
>         When you turn off journalling, you save something; when you
>         consolidate the activity into a single transaction, you save
>         something else.  What you're seeing is that the saving achieved
>         with reference to your base-line measurement by using a single
>         transaction exceeds that achieved by disabling journalling.
>
>         /Niall
>

Agreed.  But the question is: Why?  Without journaling only half as
much writing to disk should occur so why would it take longer?
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to