Hi Isuru, I think Gimantha has already discussed about this in this thread [1]. The link suggests to do lucene 'group by' queries using writing a custom facet collector.
[1]. http://mail-archives.apache.org/mod_mbox/lucene-java-user/201508.mbox/%3CCAPz8bx2j3eM9L6q=r0_XV-8=rskwct84+m3vkchhwk-hopc...@mail.gmail.com%3E Thanks. On Tue, Oct 6, 2015 at 10:59 PM, Isuru Wijesinghe <[email protected]> wrote: > Hi Anjana, > > I think the link [1] given something similar to *where* clause in sql (I > mean the *query *part is something similar to *where *clause). Here what > I really need to do is, use the count operation with *group by. * In > addition to that does luicene support for ascending and descending order > ??? > > On Tue, Oct 6, 2015 at 3:54 PM, Anjana Fernando <[email protected]> wrote: > >> Hi Isuru, >> >> You can use the REST APIs search count [1] operation. >> >> [1] >> https://docs.wso2.com/display/DAS300/Retrieving+the+Number+of+Records+Matching+the+Given+Search+Query+via+REST+API >> >> Cheers, >> Anjana. >> >> On Tue, Oct 6, 2015 at 1:04 PM, Isuru Wijesinghe <[email protected]> >> wrote: >> >>> Hi, >>> >>> I need to perform COUNT() operation through DAS REST API (an example is >>> shown below). I tried to pass COUNT() from a luciene object. But it didn't >>> work for me. Does DAS support COUNT operation through luciene ??? if not >>> how can I enable it in DAS side??? >>> >>> eg: *SELECT startedTime, processDefinitionId, COUNT(processInstanceId) >>> AS processInstanceCount FROM PROCESS_USAGE_SUMMARY GROUP BY startedTime, >>> processDefinitionId;* >>> >>> In addition to that, is that possible to pass more than one parameter to >>> the query part in luicene object, because most graphs have to provide a >>> secondary filter to get the result. As an example I need to filter the >>> result from date range as well as process id. I need something like this. >>> >>> *"query" : "timestamp : [1243214324532 TO 4654365223], processId : >>> 10035" * >>> >>> Any help will be appreciated. >>> >>> -- >>> Isuru Wijesinghe >>> *Software Engineer* >>> Mobile: 0710933706 >>> [email protected] >>> >>> _______________________________________________ >>> Dev mailing list >>> [email protected] >>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>> >>> >> >> >> -- >> *Anjana Fernando* >> Senior Technical Lead >> WSO2 Inc. | http://wso2.com >> lean . enterprise . middleware >> > > > > -- > Isuru Wijesinghe > *Software Engineer* > Mobile: 0710933706 > [email protected] > > _______________________________________________ > Dev mailing list > [email protected] > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- Thanuja Uruththirakodeeswaran Software Engineer WSO2 Inc.;http://wso2.com lean.enterprise.middleware mobile: +94 774363167
_______________________________________________ Dev mailing list [email protected] http://wso2.org/cgi-bin/mailman/listinfo/dev
