Re: Referencing incoming search terms in searchHandler XML

2016-04-14 Thread Walter Underwood
> On Apr 14, 2016, at 12:18 PM, John Bickerstaff > wrote: > > If a user types in "foobarbaz figo" I want all documents with "figo" in the > contentType field boosted above every other document in the results. This is a very common requirement that seems like a good idea, but has very bad corn

Re: Referencing incoming search terms in searchHandler XML

2016-04-14 Thread John Bickerstaff
Thanks - so this: bq=contentType:(original query text here)^1000 is exactly what I want to do to every incoming query via an entry in a custom requestHandler. Thus my question about how to reference the original query text in the requestHandler xml... I believe that if I want to do that, I'm go

Re: Referencing incoming search terms in searchHandler XML

2016-04-14 Thread Erick Erickson
Right, edismax is where I'd start. NOTE: there are about a zillion options here so you may find yourself lost in a bit of a maze for a while, but it's usually faster than coding it yourself ;). In this case, take a look at the "bq" parameter to edismax and make it something like bq=contentType:(or

Re: Referencing incoming search terms in searchHandler XML

2016-04-14 Thread John Bickerstaff
OK - that's interesting. Perhaps I'm thinking too much like a developer and just want to be able to reach into context and grab anything any time I want... Thanks for the input... = To clarify, I want to boost the document's score if the user enters a term found in the contentType field. A

Re: Referencing incoming search terms in searchHandler XML

2016-04-14 Thread Erick Erickson
You really don't do that in solrconfig.xml. This seems like an XY problem. You're trying to solve some particular use-case and accessing the terms in solrconfig.xml. You've already found the ability to configure edismax as your defType and apply boosts to particular fields... Best, Erick On Thu,

Re: Referencing incoming search terms in searchHandler XML

2016-04-14 Thread John Bickerstaff
Maybe I'm overdoing it... It seems to me that qf= text contentType^1000 would do this for me more easily - as it appears to assume the incoming search terms... However, I'd still like to know the simplest way to reference the search terms in the XML - or possibly get a URL that points the way. T

Referencing incoming search terms in searchHandler XML

2016-04-14 Thread John Bickerstaff
I have the following (essentially hard-coded) line in the Solr Admin Query UI = bq: contentType:(searchTerm1 searchTerm2 searchTerm2)^1000 = The "searchTerm" entries represent whatever the user typed into the search box. This can be one or more words. Usually less than 5. I want to put