Square brackets are inclusive and curly braces are exclusive for range queries.

I tried a similar example with the standard Solr example and it works fine:

 curl "http://localhost:8983/solr/update?commit=true"; \
 -H 'Content-type:application/json' -d '
 [{"id": "doc-1",  "price_f": 249}]'

curl "http://localhost:8983/solr/select/?q=price_f:%5b149+TO+249%5d&indent=true&wt=json";

Make sure that you don't have some other dynamic field pattern that is overriding or overlapping the one you showed us.

-- Jack Krupansky

-----Original Message----- From: alin1918
Sent: Monday, July 29, 2013 6:38 AM
To: solr-user@lucene.apache.org
Subject: solr query range upper exclusive

q=price_1_1:[197 TO 249] and q=*:*&fq=price_1_1:[197 TO 249] returns 2
records

but I have two records with the price_1_1 = 249, it seams that the upper
range is exclusive and I can't figure out why, can you help me?

<dynamicField name="price_*"                type="tfloat" indexed="true"/>

<fieldType name="tfloat" class="solr.TrieFloatField" precisionStep="8"
omitNorms="true" positionIncrementGap="0"/>




--
View this message in context: http://lucene.472066.n3.nabble.com/solr-query-range-upper-exclusive-tp4080978.html Sent from the Solr - User mailing list archive at Nabble.com.

Reply via email to