: I'm trying to think of a way to use both relevancy and date sorting in : the same search. If documents are recent (say published within the last : 2 years), I want to use all of the boost functions, BQ parameters, and : normal Lucene scoring functions, but for documents older than two years, : I don't want any of those scores to apply - only a sort by date.
Yonik recently commited some code that makes it possible to express a function query string that refers to an arbitrary param name which is evaluated as a query and the scores for each document are used as a ValueSource input for the function. I imagine you could combine this with a custom function that returns the value from one ValueSource if it's low enough (the date field) otherwise it returns the value from an alternate ValueSource (the query) -Hoss