You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@jackrabbit.apache.org by Dan Diephouse <da...@mulesource.com> on 2009/08/18 23:26:47 UTC
Wrong results from jcr:like query
I have a repository like with the following structure
/hello.wsdl/@name="hello.wsdl"
/hello.wsdl/1.0/@name="1.0"
I run the query:
//*[jcr:like(fn:lower-case(@name), '%hello.wsdl%')]
This turns into the Lucene query: "+1:name:%hello.wsdl%"
I'm getting back both nodes though, and not just the first one.
I tried both with my forked branch of 1.6/Lucene 2.4.2 (I know, I know....
just has JCR-977 patches in it) and also with 1.4.x/Lucene 2.2.0 which we
were on before we upgraded. I can get a more official recent version, but
does this ring a bell to anyone? I seem to recall seeing something about it
at some point.... If you give me an idea of what the modified Lucene query
should be I can probably provide a patch.
Dan
--
Dan Diephouse
http://mulesource.com | http://netzooid.com/blog
Re: Wrong results from jcr:like query
Posted by Marcel Reutegger <mr...@day.com>.
On Tue, Aug 18, 2009 at 23:26, Dan
Diephouse<da...@mulesource.com> wrote:
> I have a repository like with the following structure
>
> /hello.wsdl/@name="hello.wsdl"
> /hello.wsdl/1.0/@name="1.0"
>
> I run the query:
>
> //*[jcr:like(fn:lower-case(@name), '%hello.wsdl%')]
>
> This turns into the Lucene query: "+1:name:%hello.wsdl%"
>
> I'm getting back both nodes though, and not just the first one.
>
> I tried both with my forked branch of 1.6/Lucene 2.4.2 (I know, I know....
> just has JCR-977 patches in it) and also with 1.4.x/Lucene 2.2.0 which we
> were on before we upgraded. I can get a more official recent version, but
> does this ring a bell to anyone?
hmm, no. can you please try it with the current trunk and file a jira
issue if the same problem exists there?
thanks
regards
marcel
> I seem to recall seeing something about it
> at some point.... If you give me an idea of what the modified Lucene query
> should be I can probably provide a patch.
>
> Dan
> --
> Dan Diephouse
> http://mulesource.com | http://netzooid.com/blog
>