From 746da3ec3c957a6b86518fb2c46c1f85db921a30 Mon Sep 17 00:00:00 2001 From: Martin Renvoize Date: Fri, 14 May 2021 16:42:44 +0100 Subject: [PATCH] Bug 22435: Improve database update Signed-off-by: Victor Grousset/tuxayo Signed-off-by: Nick Clemens Signed-off-by: Tomas Cohen Arazi --- installer/data/mysql/atomicupdate/bug_22435.perl | 1 + 1 file changed, 1 insertion(+) diff --git a/installer/data/mysql/atomicupdate/bug_22435.perl b/installer/data/mysql/atomicupdate/bug_22435.perl index 1b14a0903d..d7dbbdd568 100644 --- a/installer/data/mysql/atomicupdate/bug_22435.perl +++ b/installer/data/mysql/atomicupdate/bug_22435.perl @@ -2,6 +2,7 @@ $DBversion = 'XXX'; # will be replaced by the RM if( CheckVersion( $DBversion ) ) { $dbh->do( "INSERT IGNORE INTO account_offset_types ( type ) VALUES ( 'CREATE' ), ( 'APPLY' )" ); $dbh->do( "UPDATE account_offsets SET type = 'CREATE' WHERE type != 'OVERDUE_INCREASE' AND type != 'OVERDUE_DECREASE' AND ( debit_id IS NULL OR credit_id IS NULL)" ); + $dbh->do( "UPDATE account_offsets SET type = 'APPLY' WHERE type != 'OVERDUE_INCREASE' AND type != 'OVERDUE_DECREASE' AND type != 'CREATE'" ); NewVersion( $DBversion, 22435, "Update offsets to CREATE type"); } -- 2.32.0