On Fri, 14 Mar 2014 07:56:57 -0700 (PDT), khaloud1987 <toumi.kha...@gmail.com> wrote:
> the problem arises when I am trying to erase lines and I have a power failure > so that it deletes rows but sometimes I have a line that is deleted from the > first table and not from the second. > (yes i have a table with this name table2 and i can't read the return value > when it fails caused by the power failure) So, after a power failure, you want both deletes to have succeeded, or none at all. That behaviour is called atomicity (the A in ACID), and the way to obtain that is to wrap the statements in a transaction. BEGIN; DELETE FROM table1 WHERE ...; DELETE FROM table2 WHERE ...; COMMIT; -- Groet, Cordialement, Pozdrawiam, Regards, Kees Nuyt _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users