Bugzilla – Attachment 11969 Details for
Bug 8724
Upgrade from NoZebra installs is broken
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 8724 - Upgrade from NoZebra installs is broken
Bug-8724---Upgrade-from-NoZebra-installs-is-broken.patch (text/plain), 5.39 KB, created by
Tomás Cohen Arazi (tcohen)
on 2012-09-04 18:07:55 UTC
(
hide
)
Description:
Bug 8724 - Upgrade from NoZebra installs is broken
Filename:
MIME Type:
Creator:
Tomás Cohen Arazi (tcohen)
Created:
2012-09-04 18:07:55 UTC
Size:
5.39 KB
patch
obsolete
>From cea1202da2f082cfb44e01377c40c65c54032dbe Mon Sep 17 00:00:00 2001 >From: Tomas Cohen Arazi <tomascohen@gmail.com> >Date: Tue, 4 Sep 2012 15:02:51 -0300 >Subject: [PATCH] Bug 8724 - Upgrade from NoZebra installs is broken >MIME-Version: 1.0 >Content-Type: text/plain; charset=UTF-8 >Content-Transfer-Encoding: 8bit >Content-Type: text/plain; charset="utf-8" > >Properly set the relevant NoZebra and QueryRemoveStopwords sysprefs to 0 to fix issues on upgrades. >Also removes the sysprefs from preferences/searching.pref > >Regards >To+ > >Sponsored-by: Universidad Nacional de Córdoba >--- > installer/data/mysql/sysprefs.sql | 2 +- > installer/data/mysql/updatedatabase.pl | 8 ++++++++ > .../en/modules/admin/preferences/searching.pref | 19 ------------------- > 3 files changed, 9 insertions(+), 20 deletions(-) > >diff --git a/installer/data/mysql/sysprefs.sql b/installer/data/mysql/sysprefs.sql >index 430585a..6e5521c 100644 >--- a/installer/data/mysql/sysprefs.sql >+++ b/installer/data/mysql/sysprefs.sql >@@ -115,7 +115,7 @@ INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES > INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('z3950NormalizeAuthor',0,'If ON, Personal Name Authorities will replace authors in biblio.author','','YesNo'); > INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ReservesNeedReturns',1,'If ON, a hold placed on an item available in this library must be checked-in, otherwise, a hold on a specific item, that is in the library & available is considered available','','YesNo'); > INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('DebugLevel',2,'Define the level of debugging information sent to the browser when errors are encountered (set to 0 in production). 0=none, 1=some, 2=most','0|1|2','Choice'); >-INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('NoZebra',1,'If ON, Zebra indexing is turned off, simpler setup, but slower searches. WARNING: using NoZebra on even modest sized collections is very slow.','','YesNo'); >+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('NoZebra',0,'If ON, Zebra indexing is turned off, simpler setup, but slower searches. WARNING: using NoZebra on even modest sized collections is very slow.','','YesNo'); > INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('SessionStorage','mysql','Use database or a temporary file for storing session data','mysql|Pg|tmp','Choice'); > INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('CircAutocompl',1,'If ON, autocompletion is enabled for the Circulation input',NULL,'YesNo'); > INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('RoutingSerials',1,'If ON, serials routing is enabled',NULL,'YesNo'); >diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl >index c6b6063..6db7916 100755 >--- a/installer/data/mysql/updatedatabase.pl >+++ b/installer/data/mysql/updatedatabase.pl >@@ -5684,6 +5684,14 @@ if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) { > SetVersion($DBversion); > } > >+$DBversion = 'XXX'; >+if (C4::Context->preference("Version") < TransformToNum($DBversion)) { >+ $dbh->do("UPDATE systempreferences SET value=0 WHERE variable='NoZebra'"); >+ $dbh->do("UPDATE systempreferences SET value=0 WHERE variable='QueryRemoveStopwords'"); >+ print "Upgrade to $DBversion done (Disable obsolete NoZebra and QueryRemoveStopwords sysprefs)\n"; >+ SetVersion ($DBversion); >+} >+ > =head1 FUNCTIONS > > =head2 TableExists($table) >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/searching.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/searching.pref >index 5176d52..2d90a83 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/searching.pref >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/searching.pref >@@ -1,18 +1,6 @@ > Searching: > Features: > - >- - pref: NoZebra >- choices: >- yes: "Don't use" >- no: Use >- - the Zebra search engine. It is recommended to use Zebra; the option to not use Zebra is deprecated and is not guaranteed to work. >- - >- - When Zebra is not in use, translate the following MARC fields to the following indexes (each line should look something like <code>'indexname' => '100a,245a,500*',</code>) >- - pref: NoZebraIndexes >- type: textarea >- class: list >- - >- - > - Perform wildcard searching (where, for example, <cite>Har</cite> would match <cite>Harry</cite> and <cite>harp</cite>) > - pref: QueryAutoTruncate > type: boolean >@@ -28,13 +16,6 @@ Searching: > no: "Don't try" > - to match similarly spelled words in a search (for example, a search for <cite>flang</cite> would also match <cite>flange</cite> and <cite>fang</cite>; REQUIRES ZEBRA). > - >- - pref: QueryRemoveStopwords >- type: boolean >- choices: >- yes: Ignore >- no: "Don't ignore" >- - stopwords specified in Koha when searching. (Only applies when Zebra is off). >- - > - pref: QueryStemming > type: boolean > choices: >-- >1.7.9.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 8724
:
11969
|
12048
|
12994