From: Bill Erickson Date: Wed, 29 Oct 2014 21:06:55 +0000 (-0400) Subject: KMAIN-110 KCLS-98 Title matches exactly X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=603881cd80450bb8f13cf4ca856fcb5ea2478b6c;p=working%2FEvergreen.git KMAIN-110 KCLS-98 Title matches exactly Cross-port: a217a39 --- diff --git a/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Driver/Pg/QueryParser.pm b/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Driver/Pg/QueryParser.pm index d7fe36ec7e..d9f5752815 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Driver/Pg/QueryParser.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Driver/Pg/QueryParser.pm @@ -1352,12 +1352,12 @@ sub flatten { $where .= "$NOT(" . $talias . ".id IS NOT NULL"; if (@{$node->phrases}) { $where .= ' AND ' . join(' AND ', map { - "${talias}.value ~* ".$self->QueryParser->quote_phrase_value($_, 1) + "${talias}.value ~* search_normalize(".$self->QueryParser->quote_phrase_value($_, 1).")" } @{$node->phrases}); } else { for my $atom (@{$node->only_real_atoms}) { next unless $atom->{content} && $atom->{content} =~ /(^\^|\$$)/; - $where .= " AND ${talias}.value ~* ".$self->QueryParser->quote_phrase_value($atom->{content}); + $where .= " AND ${talias}.value ~* search_normalize(".$self->QueryParser->quote_phrase_value($atom->{content}).")"; } } $where .= ')';