diff --git a/zcash_client_sqlite/src/wallet/init.rs b/zcash_client_sqlite/src/wallet/init.rs index 0e7c81df9..211dfedc5 100644 --- a/zcash_client_sqlite/src/wallet/init.rs +++ b/zcash_client_sqlite/src/wallet/init.rs @@ -212,7 +212,9 @@ pub fn init_accounts_table( pub fn drop_accounts_table( wdb: &WalletDb

, ) -> Result<(), SqliteClientError> { - wdb.conn.execute( "DROP TABLE accounts;", NO_PARAMS, )?; + wdb.conn.execute_batch( + "PRAGMA foreign_keys = OFF; DROP TABLE accounts; PRAGMA foreign_keys = ON;" + )?; Ok(()) }