X-Git-Url: https://git.ktnx.net/?a=blobdiff_plain;f=app%2Fsrc%2Fmain%2Fres%2Fraw%2Fsql_46.sql;h=031d201d9d3f64a7e309d1cd0e0f27820e25b5b4;hb=390a653a4424bd146f73bca3e421a0be252ee443;hp=a16c34dfbf149e4a2ac1477ff3b92475ddabfc5f;hpb=a89accc8449a3a7ed5215b750d83f1a65654ca0c;p=mobile-ledger.git diff --git a/app/src/main/res/raw/sql_46.sql b/app/src/main/res/raw/sql_46.sql index a16c34df..031d201d 100644 --- a/app/src/main/res/raw/sql_46.sql +++ b/app/src/main/res/raw/sql_46.sql @@ -1,4 +1,4 @@ --- Copyright © 2020 Damyan Ivanov. +-- Copyright © 2021 Damyan Ivanov. -- This file is part of MoLe. -- MoLe is free software: you can distribute it and/or modify it -- under the term of the GNU General Public License as published by @@ -13,6 +13,8 @@ -- You should have received a copy of the GNU General Public License -- along with MoLe. If not, see . +BEGIN TRANSACTION; + drop table pattern_accounts; drop table patterns; @@ -20,3 +22,5 @@ create table patterns(id integer not null primary key, name text not null, posit create unique index un_patterns_id on patterns(id); create table pattern_accounts(id integer not null primary key, pattern_id integer not null, position integer not null, acc text, acc_match_group integer, currency integer, currency_match_group integer, amount decimal, amount_match_group integer, comment text, comment_match_group integer, constraint fk_pattern_account_pattern foreign key(pattern_id) references patterns(id), constraint fk_pattern_account_currency foreign key(currency) references currencies(id)); create unique index un_pattern_accounts on pattern_accounts(id); + +COMMIT TRANSACTION; \ No newline at end of file