From 425d286108064c66c9156a7fb176f81d38dd4e07 Mon Sep 17 00:00:00 2001 From: Marcel de Rooy Date: Mon, 11 Dec 2017 10:09:00 +0100 Subject: [PATCH] Bug 19790: Add a db revision for existing installs Content-Type: text/plain; charset=utf-8 Since many installs may still have the additionalauthors kohafield, this patch adds a dbrev in atomicupdate to clear it. Test plan: [1] Run updatedatabase. Check that you see no additionalauthors anymore in marc_subfield_structure.kohafield. Signed-off-by: Marcel de Rooy --- installer/data/mysql/atomicupdate/bug19790.perl | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 installer/data/mysql/atomicupdate/bug19790.perl diff --git a/installer/data/mysql/atomicupdate/bug19790.perl b/installer/data/mysql/atomicupdate/bug19790.perl new file mode 100644 index 0000000..1943d33 --- /dev/null +++ b/installer/data/mysql/atomicupdate/bug19790.perl @@ -0,0 +1,6 @@ +$DBversion = 'XXX'; # will be replaced by the RM +if( CheckVersion( $DBversion ) ) { + $dbh->do( "UPDATE marc_subfield_structure SET kohafield=NULL where kohafield='additionalauthors.author'" ); + SetVersion( $DBversion ); + print "Upgrade to $DBversion done (Bug 19790 - Remove additionalauthors.author from installer files)\n"; +} -- 2.1.4