From a28cd52f15d82c772258f059d9439289a6f554c4 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Wed, 25 Nov 2015 13:29:05 +0000 Subject: [PATCH] Bug 14298: Do not insert the permission if already exists. To avoid a warning on updating from 3.20.x to 3.22, use "insert ignore into". This patch is not useful for 3.20.x. Signed-off-by: Katrin Fischer Signed-off-by: Tomas Cohen Arazi --- installer/data/mysql/updatedatabase.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index 3d52d39ba1..a61f3c0603 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -10869,7 +10869,7 @@ if ( CheckVersion($DBversion) ) { $DBversion = "3.21.00.027"; if ( CheckVersion($DBversion) ) { $dbh->do(q| - INSERT INTO permissions (module_bit, code, description) + INSERT IGNORE INTO permissions (module_bit, code, description) VALUES (1, 'self_checkout', 'Perform self checkout at the OPAC. It should be used for the patron matching the AutoSelfCheckID') |); -- 2.39.5