Hi, I am trying to modify solr's code to support stats.range, just as Solr
facet component.

For example:
q=*:*&stats=true&stats.field=fileSize&f.fileSize.stats.query=accesstime:[NOW-1MONTH
TO NOW-7days]&f.fileSize.stats.query=accesstime:[NOW-1YEAR TO
NOW-1MONTH]&f.fileSize.stats.query=fileSize:[* TO NOW-1YEAR]

The response would be like:
<lst name="stats_fields">
        <lst name="accesstime:[NOW-1MONTH TO NOW-7days]">
                <double name="min">0.0</double>
                <double name="max">1023.0</double>
                <long name="count">3990938</long>
                <long name="missing">0</long>
                <double name="sum">1.218913004E9</double>
                <double name="sumOfSquares">8.16136600016E11</double>
                <double name="mean">305.42018041873865</double>
                <double name="stddev">333.4905998856022</double>
        </lst>
        <lst name="accesstime:[NOW-1YEAR TO NOW-1MONTH]"/>
        <lst name="accesstime:[* TO NOW-1YEAR]"/>
</lst>

I think I should change code in
UnInvertedField(getStats)/SimpleStats(getStatsFields), but doesn't have clue
how to implement it yet.
Anyone can help on this, and give some idea how to implement this, thanks
very much :)



--
View this message in context: 
http://lucene.472066.n3.nabble.com/How-to-modify-Solr-StatsComponent-to-support-stats-range-tp4028991.html
Sent from the Solr - User mailing list archive at Nabble.com.

Reply via email to