From 77bdccce0b62947283beec10dc728e440bc27114 Mon Sep 17 00:00:00 2001 From: Agustin Moyano Date: Wed, 26 May 2021 15:59:00 -0300 Subject: [PATCH] Bug 27948: Add atomic update Signed-off-by: David Nind --- installer/data/mysql/atomicupdate/bug_27948.perl | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 installer/data/mysql/atomicupdate/bug_27948.perl diff --git a/installer/data/mysql/atomicupdate/bug_27948.perl b/installer/data/mysql/atomicupdate/bug_27948.perl new file mode 100644 index 0000000000..d5c6b804f9 --- /dev/null +++ b/installer/data/mysql/atomicupdate/bug_27948.perl @@ -0,0 +1,16 @@ +$DBversion = 'XXX'; # will be replaced by the RM +if( CheckVersion( $DBversion ) ) { + # you can use $dbh here like: + $dbh->do( q{ + INSERT IGNORE INTO systempreferences ( `variable`, `value`, `options`, `explanation`, `type` ) VALUES + ('ArticleRequestsDisclaimerText', '', NULL,'Enter text to enable the disclaimer stage of article request creation. Text will be displayed','Textarea') + } ); + + # or perform some test and warn + # if( !column_exists( 'biblio', 'biblionumber' ) ) { + # warn "There is something wrong"; + # } + + # Always end with this (adjust the bug info) + NewVersion( $DBversion, 27948, "Add ArticleRequestsDisclaimerText system preference"); +} -- 2.11.0