From 324fdec847581e9607e4e2c3bb259457dba6c5e1 Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Thu, 24 Jun 2021 06:20:23 +0000 Subject: [PATCH] Bug 27981: DB update Signed-off-by: Thomas Klausner --- installer/data/mysql/atomicupdate/bug_27981.pl | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100755 installer/data/mysql/atomicupdate/bug_27981.pl diff --git a/installer/data/mysql/atomicupdate/bug_27981.pl b/installer/data/mysql/atomicupdate/bug_27981.pl new file mode 100755 index 0000000000..f518c60b55 --- /dev/null +++ b/installer/data/mysql/atomicupdate/bug_27981.pl @@ -0,0 +1,17 @@ +use Modern::Perl; + +return { + bug_number => "27981", + description => "Make it possible to force 001 = biblionumber", + up => sub { + my ($args) = @_; + my ($dbh, $out) = @$args{qw(dbh out)}; + # Do you stuffs here + $dbh->do(q{ + INSERT IGNORE INTO systempreferences (variable, value, options, explanation, type) VALUES ('autoControlNumber','OFF','biblionumber|OFF', + 'Used to autogenerate a Control Number: biblionumber will be as biblionumber; OFF will leave it as is','Choice'); + }); + # Print useful stuff here + say $out "Added system preference autoControlNumber"; + }, +}; -- 2.30.2