[Koha-patches] [PATCH] bug 2559: fix search limit on Spanish language (DB rev 029)

Galen Charlton galen.charlton at liblime.com
Mon Apr 27 14:30:47 CEST 2009


Fixes bug where searching with the language limit set
to Spanish would instead retrieve Russian records.
---
 installer/data/mysql/updatedatabase.pl |   11 +++++++++++
 kohaversion.pl                         |    2 +-
 2 files changed, 12 insertions(+), 1 deletions(-)

diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl
index ae9af90..c0af961 100755
--- a/installer/data/mysql/updatedatabase.pl
+++ b/installer/data/mysql/updatedatabase.pl
@@ -2378,6 +2378,17 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
     SetVersion ($DBversion);
 }
 
+$DBversion = '3.01.00.029';
+if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
+    $dbh->do(q( UPDATE language_rfc4646_to_iso639
+                SET iso639_2_code = 'spa'
+                WHERE rfc4646_subtag = 'es'
+                AND   iso639_2_code = 'rus' )
+            );
+    print "Upgrade to $DBversion done (fixed bug 2599: using Spanish search limit retrieves Russian results)\n";
+    SetVersion ($DBversion);
+}
+
 =item DropAllForeignKeys($table)
 
   Drop all foreign keys of the table $table
diff --git a/kohaversion.pl b/kohaversion.pl
index a5c7fd5..5e89ad3 100644
--- a/kohaversion.pl
+++ b/kohaversion.pl
@@ -10,7 +10,7 @@
 use strict;
 
 sub kohaversion {
-    our $VERSION = '3.01.00.028';
+    our $VERSION = '3.01.00.029';
     # version needs to be set this way
     # so that it can be picked up by Makefile.PL
     # during install
-- 
1.5.6.5




More information about the Koha-patches mailing list