Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Message from discussion matching all documents in which a field is defined
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Matthew A. Brown  
View profile  
 More options Mar 30 2011, 6:26 pm
From: "Matthew A. Brown" <mat.a.br...@gmail.com>
Date: Wed, 30 Mar 2011 18:26:50 -0400
Local: Wed, Mar 30 2011 6:26 pm
Subject: Re: [sunspot] matching all documents in which a field is defined

Hi Ed,

It's perhaps mildly unintuitive, but you can just do:

    without(:field_name, nil)

Since Sunspot interprets nil in a filter as "has no indexed value".

Mat
On Mar 29, 2011 7:45 PM, "Ed Phillips" <e...@cronos.net> wrote:

> Hello,

> I have a rather simple question. The answer was not immediately obvious
after
> looking at the docs and a cursory search of the mailing list archives,
> hence the question.

> Solr provides some ways of querying for all documents in which a field
> is present such as "field_name:[* TO *]", or for all documents such as the
> "*:*" query.

> What are the Sunspot practices and/or idioms for such queries?

> Thank you.

> --
> You received this message because you are subscribed to the Google Groups
"Sunspot" group.
> To post to this group, send email to ruby-sunspot@googlegroups.com.
> To unsubscribe from this group, send email to

ruby-sunspot+unsubscribe@googlegroups.com.
> For more options, visit this group at

http://groups.google.com/group/ruby-sunspot?hl=en.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.