AnsweredAssumed Answered

Any idea why this Lucene search returns nothing?

Question asked by jcblitz on Oct 25, 2007
Latest reply on Oct 25, 2007 by jcblitz
I'm new to Alfresco and Lucene. I gave http://lucene.apache.org/java/docs/queryparsersyntax.html a read through but I don't see anything obvious of why this isn't returning anything.

I'm modifying the Query1.java example for the Web Service.

I've created the Query of
Query query = new Query(Constants.QUERY_LANG_LUCENE, "path:'/app:company_home/cm:" +ISO9075.encode("Pathology Reports")+"/*'");

but it's returning with "No query results found."

If I run the (almost) default query the example came with
Query query = new Query(Constants.QUERY_LANG_LUCENE, "TEXT:'pathology'");

one of the results is "row 1: {http://www.alfresco.org/model/content/1.0}path = /{http://www.alfresco.org/model/application/1.0}company_home/{http://www.alfresco.org/model/content/1.0}Pathology_x0020_Reports/{http://www.alfresco.org/model/content/1.0}_x0033_3-AML_20Form_20v1.pdf" which is what I'm trying to mimic with my query. Essentially get me everything in that path. Can anyone see what's wrong with my query?

Outcomes