lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Noble Paul നോബിള്‍ नोब्ळ् <noble.p...@corp.aol.com>
Subject Re: Conditional/Calculated Fields (is it possible?)
Date Thu, 07 May 2009 04:18:10 GMT
On Thu, May 7, 2009 at 6:15 AM, Yonik Seeley <yonik@lucidimagination.com> wrote:
> On Wed, May 6, 2009 at 7:32 AM, Andrew Ingram <andy@andrewingram.net> wrote:
>> Basically, a product has two price values and a date, the product
>> effectively has one price before the date and the other one after.
>> This poses no problem for the site itself since I can use conditional
>> logic, but I have no idea how to approach this with regards to solr
>> queries.
>>
>> The price of a product is used for both faceting and sorting and
>> should use whichever price is active at the time of the query. Is
>> there any way to do define a field whose value is a simple algorithm
>> operating on the value of other fields?
>
> Sort of - function queries.
>
> We don't have any conditional function queries yet, but that's easy.
> You can't yet sort by a function query, but we should fix that.
> You can't yet facet on a function query, but we should fix that too.

+1 we should fix this
>
> Short term, Erick's index the doc twice idea may be best.
> Long term, out-of-the-box functionality after volunteers help develop
> out the function query approach :-)

Ericks's idea is the simplest for now. Good one
>
> -Yonik
> http://www.lucidimagination.com
>



-- 
-----------------------------------------------------
Noble Paul | Principal Engineer| AOL | http://aol.com

Mime
View raw message