On Mon, Mar 30, 2009 at 11:10 PM, Shalin Shekhar Mangar < shalinman...@gmail.com> wrote:
> On Mon, Mar 30, 2009 at 11:06 PM, Walter Underwood <wunderw...@netflix.com > > wrote: > >> I think what you want to do is add in a function query that gives >> values in that range. >> > > The scale function won't work in this use-case because it will give you a > double in the given range. So you cannot do sort by score and price. For > this use-case you need to scale to an integer value in a discrete range. > Walter -- I think I misinterpreted your response. Sorry about that. You are indeed right. However, we can do scale(round(score, 2), 1, 10) or we can create a new scale function as you said. -- Regards, Shalin Shekhar Mangar.