[jira] Updated: (LUCENE-1045) SortField.AUTO doesn't work with long

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

[jira] Updated: (LUCENE-1045) SortField.AUTO doesn't work with long

Tim Allison (Jira)

     [ https://issues.apache.org/jira/browse/LUCENE-1045?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Grant Ingersoll updated LUCENE-1045:

    Attachment: LUCENE-1045-shortbyte.patch

Here's the patch that adds the missing short and byte sorting.

Will commit in the next day or two.

> SortField.AUTO doesn't work with long
> -------------------------------------
>                 Key: LUCENE-1045
>                 URL: https://issues.apache.org/jira/browse/LUCENE-1045
>             Project: Lucene - Java
>          Issue Type: Bug
>          Components: Search
>    Affects Versions: 2.2
>            Reporter: Daniel Naber
>            Assignee: Grant Ingersoll
>            Priority: Minor
>             Fix For: 2.3
>         Attachments: auto-long-sorting.diff, LUCENE-1045-shortbyte.patch, LUCENE-1045.patch, LUCENE-1045.patch, TestDateSort.java
> This is actually the same as LUCENE-463 but I cannot find a way to re-open that issue. I'm attaching a test case by dragon-fly999 at hotmail com that shows the problem and a patch that seems to fix it.
> The problem is that a long (as used for dates) cannot be parsed as an integer, and the next step is then to parse it as a float, which works but which is not correct. With the patch the following parsers are used in this order: int, long, float.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]