From e1a020da7499da67ad2f3af7cb7c80430396ae9e Mon Sep 17 00:00:00 2001 From: Martin Renvoize Date: Thu, 2 Jan 2020 12:56:19 +0000 Subject: [PATCH] Bug 24329: Correction to updatedatabase Ensure timestamp is not overwriteen during upgrade when applying updates for bug 3820 Signed-off-by: Jonathan Druart Signed-off-by: Martin Renvoize Signed-off-by: Joy Nelson (cherry picked from commit 4ac096c1a5607cc0d3b5bfacfff69e5010fdaba6) --- installer/data/mysql/updatedatabase.pl | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index c7d1259137..105b04f5cb 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -17366,9 +17366,9 @@ if( CheckVersion( $DBversion ) ) { $DBversion = '18.12.00.015'; if( CheckVersion( $DBversion ) ) { - $dbh->do( "UPDATE action_logs SET info = REPLACE(info,'cardnumber_replaced','cardnumber') WHERE module='MEMBERS' AND action='MODIFY'" ); - $dbh->do( "UPDATE action_logs SET info = REPLACE(info,'previous_cardnumber','before') WHERE module='MEMBERS' AND action='MODIFY'" ); - $dbh->do( "UPDATE action_logs SET info = REPLACE(info,'new_cardnumber','after') WHERE module='MEMBERS' AND action='MODIFY'" ); + $dbh->do( "UPDATE action_logs SET info = REPLACE(info,'cardnumber_replaced','cardnumber'), timestamp = timestamp WHERE module='MEMBERS' AND action='MODIFY'" ); + $dbh->do( "UPDATE action_logs SET info = REPLACE(info,'previous_cardnumber','before'), timestamp = timestamp WHERE module='MEMBERS' AND action='MODIFY'" ); + $dbh->do( "UPDATE action_logs SET info = REPLACE(info,'new_cardnumber','after'), timestamp = timestamp WHERE module='MEMBERS' AND action='MODIFY'" ); SetVersion( $DBversion ); print "Upgrade to $DBversion done (Bug 3820 - Update patron modification logs)\n"; -- 2.39.5