Bugzilla – Attachment 90187 Details for
Bug 21534
ElasticSearch - Wildcards not being analyzed
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 21534: Always compute wildcards
Bug-21534-Always-compute-wildcards.patch (text/plain), 1.39 KB, created by
Fridolin Somers
on 2019-05-29 13:46:08 UTC
(
hide
)
Description:
Bug 21534: Always compute wildcards
Filename:
MIME Type:
Creator:
Fridolin Somers
Created:
2019-05-29 13:46:08 UTC
Size:
1.39 KB
patch
obsolete
>From d1aadcc018655b980969271d4c89a077498104d6 Mon Sep 17 00:00:00 2001 >From: Fridolin Somers <fridolin.somers@biblibre.com> >Date: Wed, 29 May 2019 15:20:41 +0200 >Subject: [PATCH] Bug 21534: Always compute wildcards > >You get no results when searching with an hyphen + with * in query string (or with preference QueryAutoTruncate) : >ie /cgi-bin/koha/opac-search.pl?q=saints-anges* > >Looks like query-string by default does not compute wildcards, see analyze_wildcard in : >https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-query-string-query.html > >Test plan : >1) Use Elasticsearch >2) Create a record with "saints-anges" >3) Search for "saints-anges" => you get results >4) Search for "saints-anges*" => you get results >5) Search for "saints-ang*" => you get results >--- > Koha/SearchEngine/Elasticsearch/QueryBuilder.pm | 1 + > 1 file changed, 1 insertion(+) > >diff --git a/Koha/SearchEngine/Elasticsearch/QueryBuilder.pm b/Koha/SearchEngine/Elasticsearch/QueryBuilder.pm >index 084d5ad3db..0cbca55331 100644 >--- a/Koha/SearchEngine/Elasticsearch/QueryBuilder.pm >+++ b/Koha/SearchEngine/Elasticsearch/QueryBuilder.pm >@@ -92,6 +92,7 @@ sub build_query { > default_operator => 'AND', > default_field => '_all', > lenient => JSON::true, >+ analyze_wildcard => JSON::true, > fields => $options{fields} || [], > } > }; >-- >2.17.1
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 21534
:
90187
|
90207
|
90247
|
90260
|
90614