cancel
Showing results for 
Search instead for 
Did you mean: 

lucene search is finding too much!

peebles
Champ in-the-making
Champ in-the-making
In a webscript I am doing a search …

  var nodes = search.luceneSearch( path + " AND " + cddocument + " AND " + expression );

where the expression is

  PATH:"/app:company_home/sys:Cabinets//." AND @cm\:name:"logo.jpg"

But not only does this return the document with

  cm:name=logo.jpg

But it also returns documents

  cm:name=eclipse_logo.jpg
  cm:name=spring_logo.jpg

In other words, my search, which I intended as a 'is' is acting like a 'contains'.  It is also case insensitive.

The Advanced Search in the GUI behaves exactly the same, finding more than I bargained for. 

I am no lucene expert, from from the doc I read, seems something ain't right.  Can someone shed some light?
1 REPLY 1

andy
Champ on-the-rise
Champ on-the-rise
Hi

This is correct. The attribute cm:name is tokenised for full text search.

If you want to treat the filename as an identifier you need to use the QNAME field.

Cheers

Andy