+ .addMigrations(new Migration[]{new Migration(51, 52) {
+ @Override
+ public void migrate(@NonNull SupportSQLiteDatabase db) {
+ db.beginTransaction();
+ try {
+ db.execSQL("create index fk_pattern_accounts_pattern on " +
+ "pattern_accounts(pattern_id);");
+ db.execSQL("create index fk_pattern_accounts_currency on " +
+ "pattern_accounts(currency);");
+ db.setTransactionSuccessful();
+ }
+ finally {
+ db.endTransaction();
+ }
+ }
+ }
+ })