Re: [sqlite] BEGIN and Backup [was [sqlite] Problems with multiple threads?]

2006-06-07 Thread drh
"Pat Wibbeler" <[EMAIL PROTECTED]> wrote: > You can use BEGIN IMMEDIATE or BEGIN EXCLUSIVE depending on the type of > lock you'd like. > If you are just trying to make sure the database does not change while you back it up, then Jay's suggestion of BEGIN IMMEDIATE is the better approach (better t

Re: [sqlite] BEGIN and Backup [was [sqlite] Problems with multiple threads?]

2006-06-07 Thread Russell Leighton
Thx! [EMAIL PROTECTED] wrote: Russell Leighton <[EMAIL PROTECTED]> wrote: So, this was very enlightening...I have a simple backup function that I now question is correct. It does: - execute "begin" // lock from writes -copy db file to new file byte by byte - execute "commit" //

Re: [sqlite] BEGIN and Backup [was [sqlite] Problems with multiple threads?]

2006-06-07 Thread drh
Russell Leighton <[EMAIL PROTECTED]> wrote: > So, this was very enlightening...I have a simple backup function that I > now question is correct. > > It does: > - execute "begin" // lock from writes > -copy db file to new file byte by byte > - execute "commit" // unlock > > I was