Hoss, Thanks for the response.
I was able to get multiple dist queries working, however, I've noticed another problem. when using fq=_query_:"{!frange l=0 u=25 v=$qa}" qa=dist(2,44.844833,-93.03528,latitude,longitude) it returns 9,975 documents. When I change the upper limit to 250 it returns 33,241 documents. So, the filter is doing something. But, the lat/long on the documents returned puts them well beyond the limit - for example, the first document returned with an upper limit of 25 has the following values: [latitude] => 36.0275 [longitude] => -80.2073 which is 907 miles away from the originating point. Currently, my lat/lon fields are indexed using <field name="latitude" type="tdouble" indexed="true" /> <field name="longitude" type="tdouble" indexed="true" /> I have no doubt there is something I am missing, and any help would be greatly appreciated. Aaron On Mon, Jun 14, 2010 at 7:43 PM, Chris Hostetter <hossman_luc...@fucit.org> wrote: > : I am currently working with the following: > : > : {code} > : {!frange l=0 u=1 unit=mi}dist(2,32.6126, -86.3950, latitude, longitude) > : {/code} > ... > : {code} > : {!frange l=0 u=1 unit=mi}dist(2,32.6126, -86.3950, latitude, > : longitude) OR {!frange l=0 u=1 unit=mi}dist(2,44.1457, -73.8152, > : latitude, longitude) > : {/code} > ... > : I get an error. Hoping someone has an idea of how to work with > : multiple locations in a single search. > > I think yo uare confused about how that query is getting parsed ... when > SOlr sees the "{!frange" at the begining of hte param, that tells it that > the *entire* praam value should be parsed by the frange parser. The > frange parser doesn't know anything about keywords like "OR" > > What you probably want is to utilize the "_query_" hack of the > LuceneQParser so that you can parse some "Lucene" syntax (ie: A OR B) > where the clauses are then generated by using another parser... > > http://wiki.apache.org/solr/SolrQuerySyntax > > fq=_query_="{!frange l=0 u=1 unit=mi}dist(2,32.6126, -86.3950, latitude, > longitude)" OR _query_:"{!frange l=0 u=1 unit=mi}dist(2,44.1457, -73.8152, > latitude, longitude)" > > ...or a little more readable... > > fq=_query_="{!frange l=0 u=1 unit=mi v=$qa}" OR _query_:"{!frange l=0 u=1 > unit=mi v=$qb}" > qa=dist(2,32.6126, -86.3950, latitude, longitude) > qb=dist(2,44.1457, -73.8152, latitude, longitude) > > > > > -Hoss > >