Lucene and fts-search

var luceneQuery = "@somecomodel\\:"+verifyKey+":"+verifyId;
//e.g var luceneQuery = "@somecomodel\\:batchName:ratik;
var result = search.luceneSearch(luceneQuery);

===================================================

String query =  "PATH:\"/app:company_home/app:dictionary/app:space_templates/cm:"+templateName+"/cm:\"";
ResultSet rs = searchService.query(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE,  SearchService.LANGUAGE_LUCENE,query);
childList = rs.getChildAssocRefs();

===================================================

String BASE_QUERY = "PATH:\"/app:company_home/st:sites/*\" AND TYPE:\"" + SiteModel.TYPE_SITE + "\" AND @" + SomeCoModel.PREFIX_CONTENT + "\\:" +  SomeCoModel.PROP_PROJECT_NUMBER.getLocalName() + ":\"" +PROJECT_NUMBER + "\"";
ResultSet resultSet = searchService.query(StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, SearchService.LANGUAGE_FTS_ALFRESCO, query);
List<NodeRef> nodeRefs = resultSet.getNodeRefs();
===================================================
db-cmis

select D.cmis:objectId from cmis:document as D join mytestref:testAspect as A on 
D.cmis:objectId = A.cmis:objectId 
===================================================
fts-alfresco 

ASPECT:"mytestref:testAspect" OR ASPECT:"mytestref:isDocAssoc" OR ASPECT:"mytestref:isFolderAssoc"

ASPECT:"demo:hasMovedAspect" AND @demo:listOfMovedNodeRefs:"workspace://SpacesStore/3********************888"
===================================================


==================================================================
ar def =
    {
      query: "cm:destination:\"" + parentNodeRef + "\"",
       language: "fts-alfresco"
    };

    var results = search.query(def);
=======================================================================
 var def =
    {
      query: "ASPECT:\"testCo:testAspect\" OR ASPECT:\"testCo:isDocAssoc\" OR ASPECT:\"testCo:isFolderAssoc\"   ",
       language: "fts-alfresco"
    };
    var results = search.query(def);

Comments

Popular posts from this blog

Install Alfresco Content Service 6.0 on ubuntu 16 using distribution zip

Alfresco basic authentication