Bugzilla – Attachment 63174 Details for
Bug 15108
OAI-PMH provider improvements
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 15108: (QA followup) Fix atomic update file
Bug-15108-QA-followup-Fix-atomic-update-file.patch (text/plain), 2.02 KB, created by
Tomás Cohen Arazi
on 2017-05-05 15:01:22 UTC
(
hide
)
Description:
Bug 15108: (QA followup) Fix atomic update file
Filename:
MIME Type:
Creator:
Tomás Cohen Arazi
Created:
2017-05-05 15:01:22 UTC
Size:
2.02 KB
patch
obsolete
>From 19baad1b0b56e8f995d9c3ea8dae2d1d45985187 Mon Sep 17 00:00:00 2001 >From: Tomas Cohen Arazi <tomascohen@theke.io> >Date: Fri, 5 May 2017 11:38:31 -0300 >Subject: [PATCH] Bug 15108: (QA followup) Fix atomic update file > >Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> >--- > .../Bug15108-OAI-PMH_provider_improvements.perl | 21 ++++++++++++++------- > 1 file changed, 14 insertions(+), 7 deletions(-) > >diff --git a/installer/data/mysql/atomicupdate/Bug15108-OAI-PMH_provider_improvements.perl b/installer/data/mysql/atomicupdate/Bug15108-OAI-PMH_provider_improvements.perl >index 9a252cf..4cd702c 100644 >--- a/installer/data/mysql/atomicupdate/Bug15108-OAI-PMH_provider_improvements.perl >+++ b/installer/data/mysql/atomicupdate/Bug15108-OAI-PMH_provider_improvements.perl >@@ -1,11 +1,18 @@ >-$DBversion = 'XXX'; # will be replaced by the RM >+$DBversion = 'XXX'; > if( CheckVersion( $DBversion ) ) { >- $dbh->do("ALTER TABLE biblioitems ADD KEY `timestamp` (`timestamp`);"); >- $dbh->do("ALTER TABLE deletedbiblioitems ADD KEY `timestamp` (`timestamp`);"); >- $dbh->do("ALTER TABLE items ADD KEY `timestamp` (`timestamp`);"); >- $dbh->do("ALTER TABLE deleteditems ADD KEY `timestamp` (`timestamp`);"); >+ if ( !index_exists( 'biblioitems', 'timestamp' ) ) { >+ $dbh->do("ALTER TABLE biblioitems ADD KEY `timestamp` (`timestamp`);"); >+ } >+ if ( !index_exists( 'deletedbiblioitems', 'timestamp' ) ) { >+ $dbh->do("ALTER TABLE deletedbiblioitems ADD KEY `timestamp` (`timestamp`);"); >+ } >+ if ( !index_exists( 'items', 'timestamp' ) ) { >+ $dbh->do("ALTER TABLE items ADD KEY `timestamp` (`timestamp`);"); >+ } >+ if ( !index_exists( 'deleteditems', 'timestamp' ) ) { >+ $dbh->do("ALTER TABLE deleteditems ADD KEY `timestamp` (`timestamp`);"); >+ } > >- # Always end with this (adjust the bug info) > SetVersion( $DBversion ); >- print "Upgrade to $DBversion done (Bug 15108 - OAI-PMH provider improvements)\n"; >+ print "Upgrade to $DBversion done (Bug 15108: OAI-PMH provider improvements)\n"; > } >-- >2.7.4
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 15108
:
44317
|
44318
|
51962
|
52416
|
52422
|
52423
|
53853
|
53854
|
56813
|
56844
|
58058
|
58059
|
58060
|
58061
|
58062
|
58063
|
58064
|
58065
|
58072
|
58080
|
58245
|
58246
|
58247
|
58248
|
58249
|
58250
|
58251
|
60260
|
60331
|
60608
|
60835
|
60836
|
63172
|
63173
| 63174