jackrabbit-oak-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From alexparvule...@apache.org
Subject svn commit: r1393471 - /jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/lucene/LuceneIndex.java
Date Wed, 03 Oct 2012 13:10:20 GMT
Author: alexparvulescu
Date: Wed Oct  3 13:10:20 2012
New Revision: 1393471

URL: http://svn.apache.org/viewvc?rev=1393471&view=rev
Log:
OAK-347 QueryEngine 'like' interpretation error

Modified:
    jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/lucene/LuceneIndex.java

Modified: jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/lucene/LuceneIndex.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/lucene/LuceneIndex.java?rev=1393471&r1=1393470&r2=1393471&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/lucene/LuceneIndex.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/lucene/LuceneIndex.java
Wed Oct  3 13:10:20 2012
@@ -210,6 +210,8 @@ public class LuceneIndex implements Quer
                     first = first.replace("%", "*");
                 }
                 if (first.endsWith("*")) {
+                    // remove trailing "*" for prefixquery
+                    first = first.substring(0, first.length() - 1);
                     if (JCR_PATH.equals(name)) {
                         qs.add(new PrefixQuery(newPathTerm(first)));
                     } else {



Mime
View raw message