You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Jack Krupansky (JIRA)" <ji...@apache.org> on 2013/06/28 00:04:20 UTC

[jira] [Commented] (SOLR-4772) DateRoundingUpdateProcessorFactory

    [ https://issues.apache.org/jira/browse/SOLR-4772?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13695094#comment-13695094 ] 

Jack Krupansky commented on SOLR-4772:
--------------------------------------

As a temporary workaround, a StatelessScript update processor can be used to execute a concise JavaScript script to perform the desired date rounding. I just coded one today (normalize-date.js) which will appear in the next early access release of my book at the end of next week. It lets you specify the unit of truncation (no "rounding"), from second to decade. It also "normalizes" abbreviated dates such as "2012", "2012-04-15", and missing "Z". It works for multivalued data fields as well.
                
> DateRoundingUpdateProcessorFactory
> ----------------------------------
>
>                 Key: SOLR-4772
>                 URL: https://issues.apache.org/jira/browse/SOLR-4772
>             Project: Solr
>          Issue Type: Improvement
>          Components: update
>            Reporter: Upayavira
>            Priority: Minor
>         Attachments: DateRoundingUpdateProcessorFactory.zip, DateRoundingUpdateProcessorFactory.zip, RoundingUpdateProcessorFactory.zip
>
>
> A simple UpdateProcessor that rounds dates using the DateMathParser.
> At present it is not possible to combine pivot faceting with range queries. This simple UpdateProcessor allows us to round our dates on their way into Solr, giving us date fields that can be used in pivot facets.
> This can be extremely useful when using facets to plot graphs based upon log files indexed into Solr.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org