On 5 Mar 2017, at 4:11pm, Yuri <y...@rawbw.com> wrote:

> On 03/05/2017 07:20, Simon Slavin wrote:
>> If you want to delay the ending of the transaction you have to put the BEGIN 
>> in before it, and then you must put the COMMIT in after it or it won’t be 
>> committed.
> 
> The second blob write fails even after adding BEGIN before sqlite3_blob_open 
> and COMMIT after sqlite3_blob_close.

Yes, as we already established it’s because you changed the values of other 
columns in the row.  I think you’re using SQLite’s blob calls in an unexpected 
way.  They’re not meant to be used as an ongoing editor.  Adding the kind of 
support you’ve asked for would involve slowing down the routines for all the 
existing users.  Not really worth it.

I think you’re better off reading the existing BLOB value into memory using 
SELECT, editing it using standard memory-manipulation routines, then writing it 
back with an UPDATE when you’re ready.

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

Reply via email to