From f1c12b57e4344fe437fdb6d84d44b9ff2b261959 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Wed, 4 Mar 2015 12:26:34 +0100 Subject: [PATCH] [PASSED QA] Bug 5338: Use insert ignore to avoid a warning if 'SER' already exists Signed-off-by: Katrin Fischer --- installer/data/mysql/updatedatabase.pl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index 18b4411..54f0c09 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -9796,11 +9796,11 @@ if(CheckVersion($DBversion)) { $DBversion = "3.19.00.XXX"; if ( CheckVersion($DBversion) ) { $dbh->do(q| - INSERT INTO authorised_values (category, authorised_value, lib) VALUES + INSERT IGNORE INTO authorised_values (category, authorised_value, lib) VALUES ('REPORT_GROUP', 'SER', 'Serials') |); - print "Upgrade to $DBversion done (Bug 5338 - Add Serial to the report groups)\n"; + print "Upgrade to $DBversion done (Bug 5338 - Add Serial to the report groups if does not exist)\n"; SetVersion ($DBversion); } -- 1.9.1