> I am using "dismax" query to fetch docs from solr where I > have set some > boost to the each fields, > > > > If I search for query "Rock" I get following docs with some > boost value > which I have specified, > > > > <doc> > <float name="score">19.494072</float> > <int name="bitrate">120</int> > <str name="content">mp3</str> > <str name="genre">Rock</str> > <str name="id">1</str> > <str name="name">st name 1</str> > </doc> > <doc> > <float name="score">19.494052</float> > <int name="bitrate">248</int> > <str name="content">aac+</str> > <str name="genre">Rock</str> > <str name="id">2</str> > <str name="name">st name 2</str> > </doc> > <doc> > <float name="score">19.494042</float> > <int name="bitrate">127</int> > <str name="content">aac+</str> > <str name="genre">Rock</str> > <str name="id">3</str> > <str name="name">st name 3</str> > </doc> > <doc> > <float name="score">19.494032</float> > <int name="bitrate">256</int> > <str name="content">mp3</str> > <str name="genre">Rock</str> > <str name="id">4</str> > <str name="name">st name 5</str> > </doc> > > > I am looking for something below What is the best way to > achieve them ?
With filter queries. fq= > 1. Query=rock where content= mp3 where it should return > only first and > last docs where content=mp3 Assuming that content is string typed. q=rock&fq={!field f=content}mp3 > 2. Query=rock where bitrate<128 where it should return > only first and third docs where bitrate<128 &q=rock&fq:bitrate:[* TO 128] for this bitrate field must be tint type.