I'll let the example schema.xml speak for itself:
<!-- numeric field types that store and index the text
value verbatim (and hence don't support range queries,
since the
lexicographic ordering isn't equal to the numeric ordering)
-->
<fieldType name="integer" class="solr.IntField" omitNorms="true"/>
<fieldType name="long" class="solr.LongField" omitNorms="true"/>
<fieldType name="float" class="solr.FloatField" omitNorms="true"/>
<fieldType name="double" class="solr.DoubleField"
omitNorms="true"/>
<!-- 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"/>
On Apr 1, 2008, at 12:09 AM, Vinci wrote:
Hi,
One more thing: which numerical data type I should use, sfloat or
float, fot
the fq parameter?
Thank you,
Vinci
hossman wrote:
:
: How can I set a threshold value of a field so that I can filter the
result
: which is lower than the threshold? By the schema.xml or set by the
query?
fq=your_field_name:[* TO your_max_value]
or
fq=your_field_name:[your_min_value TO *]
depending on wether you want a minimum or maximum filter.
-Hoss
--
View this message in context: http://www.nabble.com/Setting-a-
Threshold-of-a-sortable-field-to-filter-the-result--
tp16367336p16411382.html
Sent from the Solr - User mailing list archive at Nabble.com.