You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-dev@lucene.apache.org by "Fuad Efendi (JIRA)" <ji...@apache.org> on 2008/08/02 15:45:44 UTC
[jira] Created: (SOLR-671) Range queries with 'slong' field type do
not retrieve correct results
Range queries with 'slong' field type do not retrieve correct results
---------------------------------------------------------------------
Key: SOLR-671
URL: https://issues.apache.org/jira/browse/SOLR-671
Project: Solr
Issue Type: Bug
Environment: SOLR-1.3-DEV
Schema:
<!-- Numeric field types that manipulate the value into
a string value that isn't human-readable in its internal form,
but with a lexicographic ordering the same as the numeric ordering,
so that range queries work correctly. -->
<fieldType name="sint" class="solr.SortableIntField" sortMissingLast="true" omitNorms="true"/>
<fieldType name="slong" class="solr.SortableLongField" sortMissingLast="true" omitNorms="true"/>
<fieldType name="sfloat" class="solr.SortableFloatField" sortMissingLast="true" omitNorms="true"/>
<fieldType name="sdouble" class="solr.SortableDoubleField" sortMissingLast="true" omitNorms="true"/>
<field name="timestamp" type="slong" indexed="true" stored="true"/>
Reporter: Fuad Efendi
Range queries always return all results (do not filter):
timestamp:[1019386401114 TO 1219386401114]
<lst name="debug">
<str name="rawquerystring">timestamp:[1019386401114 TO 1219386401114]</str>
<str name="querystring">timestamp:[1019386401114 TO 1219386401114]</str>
<str name="parsedquery">timestamp:[1019386401114 TO 1219386401114]</str>
<str name="parsedquery_toString">timestamp:[#8;#0;εごᅚ TO #8;#0;ѯ刯慚]</str>
...
<str name="QParser">OldLuceneQParser</str>
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Issue Comment Edited: (SOLR-671) Range queries with 'slong'
field type do not retrieve correct results
Posted by "Fuad Efendi (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/SOLR-671?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12619223#action_12619223 ]
funtick edited comment on SOLR-671 at 8/2/08 7:12 AM:
----------------------------------------------------------
Here is test case, similar to Arrays.sort() bug (unsigned...):
{code}
long time1 = System.currentTimeMillis();
long time2 = 30*24*3600*1000;
System.out.println(time1);
System.out.println(time1-time2);
Output:
1219389000674
1221091967970
{code}
(time1-time2) > time1!
What happens inside SOLR slong for such queries?
was (Author: funtick):
Here is test case, similar to Arrays.sort() bug (unsigned...):
{code}
long time1 = System.currentTimeMillis() - 30*24*3600*1000;
long time2 = 30*24*3600*1000;
System.out.println(time1);
System.out.println(time1-time2);
Output:
1219389000674
1221091967970
{code}
(time1-time2) > time1!
What happens inside SOLR slong for such queries?
> Range queries with 'slong' field type do not retrieve correct results
> ---------------------------------------------------------------------
>
> Key: SOLR-671
> URL: https://issues.apache.org/jira/browse/SOLR-671
> Project: Solr
> Issue Type: Bug
> Affects Versions: 1.3
> Environment: SOLR-1.3-DEV
> Schema:
> <!-- Numeric field types that manipulate the value into
> a string value that isn't human-readable in its internal form,
> but with a lexicographic ordering the same as the numeric ordering,
> so that range queries work correctly. -->
> <fieldType name="sint" class="solr.SortableIntField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="slong" class="solr.SortableLongField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="sfloat" class="solr.SortableFloatField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="sdouble" class="solr.SortableDoubleField" sortMissingLast="true" omitNorms="true"/>
> <field name="timestamp" type="slong" indexed="true" stored="true"/>
> Reporter: Fuad Efendi
> Original Estimate: 168h
> Remaining Estimate: 168h
>
> Range queries always return all results (do not filter):
> timestamp:[1019386401114 TO 1219386401114]
> <lst name="debug">
> <str name="rawquerystring">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="querystring">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="parsedquery">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="parsedquery_toString">timestamp:[#8;#0;εごᅚ TO #8;#0;ѯ刯慚]</str>
> ...
> <str name="QParser">OldLuceneQParser</str>
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (SOLR-671) Range queries with 'slong' field type do
not retrieve correct results
Posted by "Fuad Efendi (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/SOLR-671?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Fuad Efendi updated SOLR-671:
-----------------------------
Priority: Blocker (was: Major)
Affects Version/s: 1.3
> Range queries with 'slong' field type do not retrieve correct results
> ---------------------------------------------------------------------
>
> Key: SOLR-671
> URL: https://issues.apache.org/jira/browse/SOLR-671
> Project: Solr
> Issue Type: Bug
> Affects Versions: 1.3
> Environment: SOLR-1.3-DEV
> Schema:
> <!-- Numeric field types that manipulate the value into
> a string value that isn't human-readable in its internal form,
> but with a lexicographic ordering the same as the numeric ordering,
> so that range queries work correctly. -->
> <fieldType name="sint" class="solr.SortableIntField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="slong" class="solr.SortableLongField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="sfloat" class="solr.SortableFloatField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="sdouble" class="solr.SortableDoubleField" sortMissingLast="true" omitNorms="true"/>
> <field name="timestamp" type="slong" indexed="true" stored="true"/>
> Reporter: Fuad Efendi
> Priority: Blocker
> Original Estimate: 168h
> Remaining Estimate: 168h
>
> Range queries always return all results (do not filter):
> timestamp:[1019386401114 TO 1219386401114]
> <lst name="debug">
> <str name="rawquerystring">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="querystring">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="parsedquery">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="parsedquery_toString">timestamp:[#8;#0;εごᅚ TO #8;#0;ѯ刯慚]</str>
> ...
> <str name="QParser">OldLuceneQParser</str>
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (SOLR-671) Range queries with 'slong' field type
do not retrieve correct results
Posted by "Yonik Seeley (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/SOLR-671?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Yonik Seeley resolved SOLR-671.
-------------------------------
Resolution: Invalid
> Range queries with 'slong' field type do not retrieve correct results
> ---------------------------------------------------------------------
>
> Key: SOLR-671
> URL: https://issues.apache.org/jira/browse/SOLR-671
> Project: Solr
> Issue Type: Test
> Environment: SOLR-1.3-DEV
> Schema:
> <!-- Numeric field types that manipulate the value into
> a string value that isn't human-readable in its internal form,
> but with a lexicographic ordering the same as the numeric ordering,
> so that range queries work correctly. -->
> <fieldType name="sint" class="solr.SortableIntField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="slong" class="solr.SortableLongField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="sfloat" class="solr.SortableFloatField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="sdouble" class="solr.SortableDoubleField" sortMissingLast="true" omitNorms="true"/>
> <field name="timestamp" type="slong" indexed="true" stored="true"/>
> Reporter: Fuad Efendi
> Priority: Trivial
> Original Estimate: 168h
> Remaining Estimate: 168h
>
> Range queries always return all results (do not filter):
> timestamp:[1019386401114 TO 1219386401114]
> <lst name="debug">
> <str name="rawquerystring">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="querystring">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="parsedquery">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="parsedquery_toString">timestamp:[#8;#0;εごᅚ TO #8;#0;ѯ刯慚]</str>
> ...
> <str name="QParser">OldLuceneQParser</str>
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (SOLR-671) Range queries with 'slong' field type do
not retrieve correct results
Posted by "Fuad Efendi (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/SOLR-671?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Fuad Efendi updated SOLR-671:
-----------------------------
Priority: Trivial (was: Major)
Issue Type: Test (was: Bug)
Affects Version/s: (was: 1.3)
> Range queries with 'slong' field type do not retrieve correct results
> ---------------------------------------------------------------------
>
> Key: SOLR-671
> URL: https://issues.apache.org/jira/browse/SOLR-671
> Project: Solr
> Issue Type: Test
> Environment: SOLR-1.3-DEV
> Schema:
> <!-- Numeric field types that manipulate the value into
> a string value that isn't human-readable in its internal form,
> but with a lexicographic ordering the same as the numeric ordering,
> so that range queries work correctly. -->
> <fieldType name="sint" class="solr.SortableIntField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="slong" class="solr.SortableLongField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="sfloat" class="solr.SortableFloatField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="sdouble" class="solr.SortableDoubleField" sortMissingLast="true" omitNorms="true"/>
> <field name="timestamp" type="slong" indexed="true" stored="true"/>
> Reporter: Fuad Efendi
> Priority: Trivial
> Original Estimate: 168h
> Remaining Estimate: 168h
>
> Range queries always return all results (do not filter):
> timestamp:[1019386401114 TO 1219386401114]
> <lst name="debug">
> <str name="rawquerystring">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="querystring">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="parsedquery">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="parsedquery_toString">timestamp:[#8;#0;εごᅚ TO #8;#0;ѯ刯慚]</str>
> ...
> <str name="QParser">OldLuceneQParser</str>
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (SOLR-671) Range queries with 'slong' field type do
not retrieve correct results
Posted by "Fuad Efendi (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/SOLR-671?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Fuad Efendi updated SOLR-671:
-----------------------------
Priority: Trivial (was: Blocker)
Issue Type: Test (was: Bug)
I executed another query which works fine:
timestamp:[* TO 10000000] - 0 results
Finally found it works...
Please close.
> Range queries with 'slong' field type do not retrieve correct results
> ---------------------------------------------------------------------
>
> Key: SOLR-671
> URL: https://issues.apache.org/jira/browse/SOLR-671
> Project: Solr
> Issue Type: Test
> Affects Versions: 1.3
> Environment: SOLR-1.3-DEV
> Schema:
> <!-- Numeric field types that manipulate the value into
> a string value that isn't human-readable in its internal form,
> but with a lexicographic ordering the same as the numeric ordering,
> so that range queries work correctly. -->
> <fieldType name="sint" class="solr.SortableIntField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="slong" class="solr.SortableLongField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="sfloat" class="solr.SortableFloatField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="sdouble" class="solr.SortableDoubleField" sortMissingLast="true" omitNorms="true"/>
> <field name="timestamp" type="slong" indexed="true" stored="true"/>
> Reporter: Fuad Efendi
> Priority: Trivial
> Original Estimate: 168h
> Remaining Estimate: 168h
>
> Range queries always return all results (do not filter):
> timestamp:[1019386401114 TO 1219386401114]
> <lst name="debug">
> <str name="rawquerystring">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="querystring">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="parsedquery">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="parsedquery_toString">timestamp:[#8;#0;εごᅚ TO #8;#0;ѯ刯慚]</str>
> ...
> <str name="QParser">OldLuceneQParser</str>
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (SOLR-671) Range queries with 'slong' field type do
not retrieve correct results
Posted by "Fuad Efendi (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/SOLR-671?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Fuad Efendi updated SOLR-671:
-----------------------------
Priority: Major (was: Trivial)
Issue Type: Bug (was: Test)
Here is test case, similar to Arrays.sort() bug (unsigned...):
{code}
long time1 = System.currentTimeMillis() - 30*24*3600*1000;
long time2 = 30*24*3600*1000;
System.out.println(time1);
System.out.println(time1-time2);
Output:
1219389000674
1221091967970
{code}
(time1-time2) > time1!
What happens inside SOLR slong for such queries?
> Range queries with 'slong' field type do not retrieve correct results
> ---------------------------------------------------------------------
>
> Key: SOLR-671
> URL: https://issues.apache.org/jira/browse/SOLR-671
> Project: Solr
> Issue Type: Bug
> Affects Versions: 1.3
> Environment: SOLR-1.3-DEV
> Schema:
> <!-- Numeric field types that manipulate the value into
> a string value that isn't human-readable in its internal form,
> but with a lexicographic ordering the same as the numeric ordering,
> so that range queries work correctly. -->
> <fieldType name="sint" class="solr.SortableIntField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="slong" class="solr.SortableLongField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="sfloat" class="solr.SortableFloatField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="sdouble" class="solr.SortableDoubleField" sortMissingLast="true" omitNorms="true"/>
> <field name="timestamp" type="slong" indexed="true" stored="true"/>
> Reporter: Fuad Efendi
> Original Estimate: 168h
> Remaining Estimate: 168h
>
> Range queries always return all results (do not filter):
> timestamp:[1019386401114 TO 1219386401114]
> <lst name="debug">
> <str name="rawquerystring">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="querystring">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="parsedquery">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="parsedquery_toString">timestamp:[#8;#0;εごᅚ TO #8;#0;ѯ刯慚]</str>
> ...
> <str name="QParser">OldLuceneQParser</str>
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (SOLR-671) Range queries with 'slong' field type
do not retrieve correct results
Posted by "Fuad Efendi (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/SOLR-671?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12619227#action_12619227 ]
Fuad Efendi commented on SOLR-671:
----------------------------------
{code}
long time1 = System.currentTimeMillis();
long time2 = 30*24*3600*1000;
long time3 = time1 - time2;
System.out.println("Time1: "+time1);
System.out.println("Time2: " +time2);
System.out.println("Time3: "+time3);
Time1: 1217686478242
Time2: -1702967296
Time3: 1219389445538
{code}
bug is obvious...
{code}
long time1 = System.currentTimeMillis();
long time2 = 30*24*3600*1000L;
long time3 = time1 - time2;
System.out.println("Time1: "+time1);
System.out.println("Time2: " +time2);
System.out.println("Time3: "+time3);
Time1: 1217686559557
Time2: 2592000000
Time3: 1215094559557
{code}
Close it...
> Range queries with 'slong' field type do not retrieve correct results
> ---------------------------------------------------------------------
>
> Key: SOLR-671
> URL: https://issues.apache.org/jira/browse/SOLR-671
> Project: Solr
> Issue Type: Bug
> Environment: SOLR-1.3-DEV
> Schema:
> <!-- Numeric field types that manipulate the value into
> a string value that isn't human-readable in its internal form,
> but with a lexicographic ordering the same as the numeric ordering,
> so that range queries work correctly. -->
> <fieldType name="sint" class="solr.SortableIntField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="slong" class="solr.SortableLongField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="sfloat" class="solr.SortableFloatField" sortMissingLast="true" omitNorms="true"/>
> <fieldType name="sdouble" class="solr.SortableDoubleField" sortMissingLast="true" omitNorms="true"/>
> <field name="timestamp" type="slong" indexed="true" stored="true"/>
> Reporter: Fuad Efendi
> Original Estimate: 168h
> Remaining Estimate: 168h
>
> Range queries always return all results (do not filter):
> timestamp:[1019386401114 TO 1219386401114]
> <lst name="debug">
> <str name="rawquerystring">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="querystring">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="parsedquery">timestamp:[1019386401114 TO 1219386401114]</str>
> <str name="parsedquery_toString">timestamp:[#8;#0;εごᅚ TO #8;#0;ѯ刯慚]</str>
> ...
> <str name="QParser">OldLuceneQParser</str>
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.