So,
I found an interesting behavior:
For facets, if you want to get all values for a specific index, you
have to have enable_star:true and specify "*". i.e. :conditions =>
{:index => '*'}
For attributes, if you want to get all values for a specific
attribute, you just specify "". i.e. :width => {:index => ''}
Pat: I'd like to return all conditions if no value is being sent to my
server from the client. I.E., if there's a facet, and none of its
values are selected, I'd prefer to just send everything back... Let me
know if it makes sense.
Manish
On Aug 28, 1:01 pm, Pat Allan <[email protected]> wrote:
> Why not just not specify the condition?
>
> --
> Pat
>
> On 28/08/2009, at 5:53 PM, mrmanishs wrote:
>
>
>
> > Pat,
>
> > I tried that, :index => '' seems to brings back 0 results. The
> > min_infix_len is set to 3.
>
> > Manish
>
> > On Aug 28, 12:32 pm, Pat Allan <[email protected]> wrote:
> >> Not entirely sure how Sphinx will handle it - but what about:
> >> :index => ''
>
> >> --
> >> Pat
>
> >> On 28/08/2009, at 4:02 PM, mrmanishs wrote:
>
> >>> Ok, an updated, if i enable_star:true, the '*', works. Is there a
> >>> way
> >>> to do this without enabling_star?
>
> >>> On Aug 28, 10:49 am, mrmanishs <[email protected]> wrote:
> >>>> Hello,
>
> >>>> I looked around TS group, but couldn't find anything with this
> >>>> question. I'm trying to do search results based if there are values
> >>>> or
> >>>> not for a specific indexed variable. I was thinking to do dynamic
> >>>> conditions, I can do something like :
>
> >>>> :conditions => {:index => 'value'} if I have a value,
> >>>> and :conditions
> >>>> => {:index => '*'} if there is no value( I want to get all the
> >>>> results). How can I do this, or is there an alternative way I
> >>>> should
> >>>> be looking to do this?
>
> >>>> Thanks.
>
> >>>> Manish
>
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Thinking Sphinx" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/thinking-sphinx?hl=en
-~----------~----~----~----~------~----~------~--~---