> On Feb 27, 2017, at 9:42 PM, Walter Underwood <wun...@wunderwood.org> wrote:
> Pretty ready to give up. The documentation around function queries and params 
> is not working for me, though I’ve been using Solr for ten years. I have 
> figured out a lot of systems. This is impenetrable.

Here’s how I (try to) explain it in Solr training:

    There’s plain uncurly bracketed parameter substitution.  This is where a 
feature (say local params, or function queries) is designed to indirect an 
exact parameter and pull it in:

        /select?q=*:*&fq={!terms f=id v=$id_list}&id_list=1,2,3

    And then there’s macro substitution, with curly bracketed syntax, and this 
is an in place string substitution allowing gluing of things together:

      /select?q=*:*&sort=${sort_field_name} desc&sort_field_name=price

When in doubt, the curly bracketed syntax actually should do the trick, but 
there’s always the fun aspect of whitespace and escaping and quoting and such, 
so it is tricky business.   A browser, some trial-and-error, and hopefully some 
tips and tricks like these that emerge online will be helpful in demystifying 
this and making it more accessible and useful/usable.

        Erik

Reply via email to