Bugzilla – Attachment 67688 Details for
Bug 13766
Make biblioitems.ean longer and add index
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 13766 - Follow-up - use index_exists()
Bug-13766---Follow-up---use-indexexists.patch (text/plain), 1.48 KB, created by
Marcel de Rooy
on 2017-10-06 10:25:28 UTC
(
hide
)
Description:
Bug 13766 - Follow-up - use index_exists()
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2017-10-06 10:25:28 UTC
Size:
1.48 KB
patch
obsolete
>From 8a23e0380809236cc55c352b5d5179085fdfe2bd Mon Sep 17 00:00:00 2001 >From: Koha instance kohadev-koha <kohadev-koha@kohadevbox> >Date: Mon, 4 Sep 2017 20:36:38 +0000 >Subject: [PATCH] Bug 13766 - Follow-up - use index_exists() >Content-Type: text/plain; charset=utf-8 > >Changes check for existing index to use index_exists. >Also checks deletedbiblioitems for an existing ean index >and drops it if one is found. > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >--- > installer/data/mysql/atomicupdate/bug_13766_fix_ean.perl | 7 ++++--- > 1 file changed, 4 insertions(+), 3 deletions(-) > >diff --git a/installer/data/mysql/atomicupdate/bug_13766_fix_ean.perl b/installer/data/mysql/atomicupdate/bug_13766_fix_ean.perl >index bfd7dd1..21d1fc1 100644 >--- a/installer/data/mysql/atomicupdate/bug_13766_fix_ean.perl >+++ b/installer/data/mysql/atomicupdate/bug_13766_fix_ean.perl >@@ -1,11 +1,12 @@ > $DBversion = "XXX"; > if(CheckVersion($DBversion)) { > # Drop index that might exist because of bug 5337 >- my $temp = $dbh->selectall_arrayref(q{ >- SHOW INDEXES FROM biblioitems WHERE key_name = 'ean' }); >- if( @$temp > 0 ) { >+ if( index_exists('biblioitems', 'ean')) { > $dbh->do(q{ ALTER TABLE biblioitems DROP INDEX ean }); > } >+ if( index_exists('deletedbiblioitems', 'ean')) { >+ $dbh->do(q{ ALTER TABLE deletedbiblioitems DROP INDEX ean }); >+ } > > # Change data type of column > $dbh->do(q{ ALTER TABLE biblioitems MODIFY COLUMN ean MEDIUMTEXT default NULL }); >-- >2.1.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 13766
:
36233
|
36251
|
66146
|
66147
|
66744
|
66825
|
67687
| 67688