Ah ha, perfect. That worked brilliantly. In case anyone is interested, it turns out that defining "id score" as the field list for the standard request handler in solrconfig.xml does the same thing.

  <requestHandler name="standard" class="solr.StandardRequestHandler">
        <!-- default values for query parameters -->
         <lst name="defaults">
           <str name="echoParams">explicit</str>
           <str name="fl">id score</str>
        </lst>
  </requestHandler>

Thanks for the help,

-jrr

Henrib wrote:
I believe that keeping you code as is but initializing the query parameters
should do the trick:
....
HashMap params = new HashMap();
params.add("fl", "id score"); // field list is id & score
...
Regards

Reply via email to