In a normal query multiple fl parameters are additive, but they collectively override whatever fl parameter(s) may have been specified in "defaults", right? I mean, that's why Solr has "appends" in addition to "defaults", right"?
Ah, but I see in the JSON Request API doc that it says "Multi-valued elements like fields and filter are appended", seeming to imply that the "defaults" section will be treated as if it were "appends", it would seem, at least for how "fields" is treated. See: https://cwiki.apache.org/confluence/display/solr/JSON+Request+API Filter seems to make sense for this auto-appends mode, but fields/fl don't seem to benefit from appending rather than treating the defaults section in the traditional manner, I think. -- Jack Krupansky On Tue, Dec 15, 2015 at 9:06 PM, Yonik Seeley <[email protected]> wrote: > Multiple "fl" parameters are additive, so it would make sense that > "fields" is also (for fl and field in the same request). If that's > true for "fl" as a default and "fl" as a query param, then it seems > like that should be true for the other variants. > > If "fl" as a query param and "fl" in a JSON params block don't act the > same, that should probably be a bug? > > -Yonik > > > On Tue, Dec 15, 2015 at 7:55 PM, Jack Krupansky > <[email protected]> wrote: > > Yonik? The doc is weak in this area. In fact, I see a comment on it from > > Cassandra directed to you to verify the JSON to parameter mapping. It > would > > be nice to have a clear statement of the semantics for JSON "fields" > > parameter and how it may or may not interact with the Solr fl parameter. > > > > -- Jack Krupansky > > > > On Thu, Dec 10, 2015 at 3:55 PM, Ryan Josal <[email protected]> wrote: > >> > >> I didn't see a Jira open in this, so I wanted to see if it's expected. > If > >> you pass "fields":[...] in a SOLR JSON API request, it does not override > >> what's the default in the handler config. I had fl=* as a default, so > I saw > >> "fields" have no effect, while "params":{"fl":...} worked as expected. > >> After stepping through the debugger I noticed it was just appending > "fields" > >> at the end of everything else (including after solr config appends, if > it > >> makes a difference). > >> > >> If this is not expected I will create a Jira and maybe have time to > >> provide a patch. > >> > >> Ryan > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > >
