Author: yonik
Date: Thu Oct 8 15:15:50 2009
New Revision: 823199
URL: http://svn.apache.org/viewvc?rev=823199&view=rev
Log:
SOLR-1478: use _docid_ to sort by the lucene docid
Modified:
lucene/solr/trunk/src/java/org/apache/solr/search/QueryParsing.java
Modified: lucene/solr/trunk/src/java/org/apache/solr/search/QueryParsing.java
URL:
http://svn.apache.org/viewvc/lucene/solr/trunk/src/java/org/apache/solr/search/QueryParsing.java?rev=823199&r1=823198&r2=823199&view=diff
==============================================================================
--- lucene/solr/trunk/src/java/org/apache/solr/search/QueryParsing.java
(original)
+++ lucene/solr/trunk/src/java/org/apache/solr/search/QueryParsing.java Thu Oct
8 15:15:50 2009
@@ -45,14 +45,14 @@
* @version $Id$
*/
public class QueryParsing {
- /** the SolrParam used to override the QueryParser "default operator" */
- public static final String OP = "q.op";
+ public static final String OP = "q.op"; // the SolrParam used to override
the QueryParser "default operator"
public static final String V = "v"; // value of this parameter
public static final String F = "f"; // field that a query or command
pertains to
public static final String TYPE = "type";// type of this query or command
public static final String DEFTYPE = "defType"; // default type for any
direct subqueries
public static final String LOCALPARAM_START = "{!";
public static final char LOCALPARAM_END = '}';
+ public static final String DOCID = "_docid_";
/**
* Helper utility for parsing a query using the Lucene QueryParser syntax.
@@ -266,7 +266,7 @@
else {
lst[i] = new SortField(null, SortField.SCORE, true);
}
- } else if ("#".equals(part)) {
+ } else if (DOCID.equals(part)) {
lst[i] = new SortField(null, SortField.DOC, top);
}
else {