https://www.sqlite.org/foreignkeys.html#fk_deferred If take you alook at the SQLite docs and run through the examples you'll find foreign key constraints do not work with dbui.