Bugzilla – Attachment 7498 Details for
Bug 7509
Create index for items.itemcallnumber
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
patch
0001-bug_7509-Added-index-on-items-itemcallnumber.patch (text/plain), 1.94 KB, created by
Srdjan Jankovic
on 2012-02-08 02:25:26 UTC
(
hide
)
Description:
patch
Filename:
MIME Type:
Creator:
Srdjan Jankovic
Created:
2012-02-08 02:25:26 UTC
Size:
1.94 KB
patch
obsolete
>From 447ce0c3ffd31609a75930747a752ddccfe533a0 Mon Sep 17 00:00:00 2001 >From: Srdjan Jankovic <srdjan@catalyst.net.nz> >Date: Wed, 8 Feb 2012 15:23:39 +1300 >Subject: [PATCH] bug_7509: Added index on items itemcallnumber > >--- > installer/data/mysql/kohastructure.sql | 1 + > installer/data/mysql/updatedatabase.pl | 8 ++++++++ > 2 files changed, 9 insertions(+), 0 deletions(-) > >diff --git a/installer/data/mysql/kohastructure.sql b/installer/data/mysql/kohastructure.sql >index 37113c2..34bf1d6 100644 >--- a/installer/data/mysql/kohastructure.sql >+++ b/installer/data/mysql/kohastructure.sql >@@ -1045,6 +1045,7 @@ CREATE TABLE `items` ( -- holdings/item information > KEY `itembibnoidx` (`biblionumber`), > KEY `homebranch` (`homebranch`), > KEY `holdingbranch` (`holdingbranch`), >+ KEY (itemcallnumber), > CONSTRAINT `items_ibfk_1` FOREIGN KEY (`biblioitemnumber`) REFERENCES `biblioitems` (`biblioitemnumber`) ON DELETE CASCADE ON UPDATE CASCADE, > CONSTRAINT `items_ibfk_2` FOREIGN KEY (`homebranch`) REFERENCES `branches` (`branchcode`) ON UPDATE CASCADE, > CONSTRAINT `items_ibfk_3` FOREIGN KEY (`holdingbranch`) REFERENCES `branches` (`branchcode`) ON UPDATE CASCADE >diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl >index 099dfb9..dc79bd9 100755 >--- a/installer/data/mysql/updatedatabase.pl >+++ b/installer/data/mysql/updatedatabase.pl >@@ -4663,6 +4663,14 @@ ENDOFRENEWAL > print "Upgrade to $DBversion done (Added a system preference to allow renewal of Patron account either from todays date or from existing expiry date in the patrons account.)\n"; > SetVersion($DBversion); > } >+ >+$DBversion = "3.07.00.XXX"; >+if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) { >+ $dbh->do("ALTER TABLE items ADD KEY (itemcallnumber)" >+ print "Upgrade to $DBversion done (Added index on items.itemcallnumber)\n"; >+ SetVersion($DBversion); >+} >+ > =head1 FUNCTIONS > > =head2 DropAllForeignKeys($table) >-- >1.6.5 >
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 7509
:
7498
|
7513
|
7516
|
7603
|
7695