cancel
Showing results for 
Search instead for 
Did you mean: 

Category based search

abirb
Champ in-the-making
Champ in-the-making
Hi,,

I am using the following query to search docs attached to a specific category ("ABC") in a particular path  ,


    
 scat="@cm\:name:\"" + "ABC" + "\"+TYPE:\"cm:category\"+";
      spath="PATH:\"/app:company_home/cm:XYZ/cm:Notification" + "//*\"";
      scontent="@\\{http\\://www.alfresco.org/model/content/1.0\\}content.mimetype:text/plain + ";
      queryString=scat + spath+scontent;

Upon execution no results are returned , but when i remove the category criteria from the query string the results seem to be OK , am i using anything which is not currently supported with Alfresco 2.2 ??
2 REPLIES 2

mikeh
Star Contributor
Star Contributor
Your current query is looking for files of type "cm:category" called "ABC" in the "Notification" folder.

Check the wiki for the correct Lucene query:
http://wiki.alfresco.com/wiki/Search#Category_Queries

Mike

abirb
Champ in-the-making
Champ in-the-making
Thanks Mike for the Link, I have been able to modify the required query , which is something like

"@cm\:generalclassifiable/" + "ABC" + "/* + PATH:\"/app:company_home/cm:XXX/cm:Notification" + "//*\"";