On May 28, 2010, at 10:54 PM, Robert Nickel wrote: > I notice that the foreign key clause > (http://www.sqlite.org/syntaxdiagrams.html#foreign-key-clause) does > not > include a conflict clause > (http://www.sqlite.org/syntaxdiagrams.html#conflict-clause). I always > specify "ON CONFLICT ROLLBACK" with my other constraints, but what > will > happen when a foreign key violation occurs within a transaction? > Will we > see the default "ABORT" behavior as with other constraints?
Yes. A failed immediate FK constraint is like an ABORT (statement rollback only). > How do I get > it to rollback the entire transaction in such a case? Can't be done. You'll have to use triggers instead of foreign keys if you need this. _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users