Archive of RubyForge sup-talk mailing list
 help / color / mirror / Atom feed
* [sup-talk] searches
@ 2010-08-05  2:14 Brian May
  2010-08-05 13:49 ` John Bent
  2010-08-05 14:35 ` Mark Alexander
  0 siblings, 2 replies; 6+ messages in thread
From: Brian May @ 2010-08-05  2:14 UTC (permalink / raw)
  To: sup-talk

Hello,

Where is the best documentation on performing searches?

I have noticed some quirks:

\label:VLSCI

finds nothing, even though lots of emails are labeled VLSCI.

\label:vlsci

finds all these emails.

\label:vlsci \label:unread

finds all vlsci OR unread emails - I would have assumed that should be AND?

How do I perform and AND operation?

Thanks
-- 
Brian May <brian@microcomaustralia.com.au>
_______________________________________________
sup-talk mailing list
sup-talk@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-talk


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [sup-talk] searches
  2010-08-05  2:14 [sup-talk] searches Brian May
@ 2010-08-05 13:49 ` John Bent
  2010-08-05 14:25   ` Gregor Hoffleit
  2010-08-05 14:35 ` Mark Alexander
  1 sibling, 1 reply; 6+ messages in thread
From: John Bent @ 2010-08-05 13:49 UTC (permalink / raw)
  To: sup-talk

Excerpts from Brian May's message of Wed Aug 04 20:14:14 -0600 2010:
> Hello,
> 
> Where is the best documentation on performing searches?
> 
> I have noticed some quirks:
> 
> \label:VLSCI
> 
> finds nothing, even though lots of emails are labeled VLSCI.
> 
> \label:vlsci
> 
> finds all these emails.
> 
> \label:vlsci \label:unread
> 
> finds all vlsci OR unread emails - I would have assumed that should be AND?
> 
The above looks like you are doing them one at a time.  If you do this:

\label:vlsci label:unread

that should do what you want.

Also, on the search results view, hitting '|' let you refine the search
so:
\label:vlsci | label:unread

should also do what you want.
-- 
Thanks,

John 
_______________________________________________
sup-talk mailing list
sup-talk@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-talk


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [sup-talk] searches
  2010-08-05 13:49 ` John Bent
@ 2010-08-05 14:25   ` Gregor Hoffleit
  2010-08-09  5:59     ` Brian May
  0 siblings, 1 reply; 6+ messages in thread
From: Gregor Hoffleit @ 2010-08-05 14:25 UTC (permalink / raw)
  To: sup-talk

* John Bent <johnbent@lanl.gov> [Do Aug 05 15:49:38 +0200 2010]
> Excerpts from Brian May's message of Wed Aug 04 20:14:14 -0600 2010:
> > Where is the best documentation on performing searches?
> > 
> > I have noticed some quirks:
> > 
> > \label:VLSCI
> > 
> > finds nothing, even though lots of emails are labeled VLSCI.
> > 
> > \label:vlsci
> > 
> > finds all these emails.
> > 
> > \label:vlsci \label:unread
> > 
> > finds all vlsci OR unread emails - I would have assumed that should be AND?

I fell into these traps as well (there was a thread in this list two
months ago, search for this message: 1276181871-sup-2536@zyrg.net).

I started to rewrite the page SearchingMail in the Wiki:
http://sup.rubyforge.org/wiki/wiki.pl?SearchingMail

The information on that page should be correct, but certainly is not
complete. Neither is it easy to grok.

As a start, the basic query language is described in
http://xapian.org/docs/queryparser.html.


Some stumbling points about searching in Sup:

- By default, query terms are combined with AND
- Exception: Query terms within the same field type are combined as OR

I.e. a search for "label:ruby-talk subject:\[ANN\]" (without the
quotes!) is equivalent to "label:ruby-talk AND subject:\[ANN\]".

In contrast, the search "subject:apples subject:oranges" is equivalent
to "subject:apples OR subject:oranges"!

> The above looks like you are doing them one at a time.  If you do this:
> 
> \label:vlsci label:unread
> 
> that should do what you want.

Wrong. As these are two queries in the same field type, they are ORed.

The get the result you're expecting, you must search for
"label:vlsci AND label:unread" (without the quotes).

> Also, on the search results view, hitting '|' let you refine the search
> so:
> \label:vlsci | label:unread
> 
> should also do what you want.

Again, this is wrong. Refining a search will just let you append or 
edit the current query. I.e. after hitting '|' you should append
"AND label:unread" to the query string.


I would really welcome if somebody with a little more insight than me
could take the time to update the documentation about searching in Sup.


    Gregor Hoffleit
_______________________________________________
sup-talk mailing list
sup-talk@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-talk


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [sup-talk] searches
  2010-08-05  2:14 [sup-talk] searches Brian May
  2010-08-05 13:49 ` John Bent
@ 2010-08-05 14:35 ` Mark Alexander
  1 sibling, 0 replies; 6+ messages in thread
From: Mark Alexander @ 2010-08-05 14:35 UTC (permalink / raw)
  To: Brian May; +Cc: sup-talk

Excerpts from Brian May's message of Wed Aug 04 22:14:14 -0400 2010:
> How do I perform and AND operation?

You use the AND operator :-) .  Apparently it's a known bug that
Xapian doesn't do AND as the implied operator when there is none
specified.  So I do things like this:

  is:unread AND is:inbox AND label:widgets
_______________________________________________
sup-talk mailing list
sup-talk@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-talk


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [sup-talk] searches
  2010-08-05 14:25   ` Gregor Hoffleit
@ 2010-08-09  5:59     ` Brian May
  2010-08-09 20:19       ` Marc Hartstein
  0 siblings, 1 reply; 6+ messages in thread
From: Brian May @ 2010-08-09  5:59 UTC (permalink / raw)
  To: Gregor Hoffleit; +Cc: sup-talk

On 6 August 2010 00:25, Gregor Hoffleit <gregor@hoffleit.de> wrote:
> I fell into these traps as well (there was a thread in this list two
> months ago, search for this message: 1276181871-sup-2536@zyrg.net).
>
> I started to rewrite the page SearchingMail in the Wiki:
> http://sup.rubyforge.org/wiki/wiki.pl?SearchingMail
>
> The information on that page should be correct, but certainly is not
> complete. Neither is it easy to grok.
>
> As a start, the basic query language is described in
> http://xapian.org/docs/queryparser.html.
>
>
> Some stumbling points about searching in Sup:
>
> - By default, query terms are combined with AND
> - Exception: Query terms within the same field type are combined as OR
>
> I.e. a search for "label:ruby-talk subject:\[ANN\]" (without the
> quotes!) is equivalent to "label:ruby-talk AND subject:\[ANN\]".
>
> In contrast, the search "subject:apples subject:oranges" is equivalent
> to "subject:apples OR subject:oranges"!

Ok, thanks for the information.

How do I search for all messages not containing a label? I tried:

not label:mylabel
! label:mylabel
~label:mylabel
-label:mylabel

The first finds no results. The rest are the same as "label:mylabel".

What am I doing wrong here?

What do the above searchs really do?
-- 
Brian May <brian@microcomaustralia.com.au>
_______________________________________________
sup-talk mailing list
sup-talk@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-talk


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [sup-talk] searches
  2010-08-09  5:59     ` Brian May
@ 2010-08-09 20:19       ` Marc Hartstein
  0 siblings, 0 replies; 6+ messages in thread
From: Marc Hartstein @ 2010-08-09 20:19 UTC (permalink / raw)
  To: sup-talk


[-- Attachment #1.1: Type: text/plain, Size: 658 bytes --]

Excerpts from Brian May's message of Mon Aug 09 01:59:16 -0400 2010:
> How do I search for all messages not containing a label? I tried:

Looking at http://xapian.org/docs/queryparser.html, it looks like "pure
not" is disabled, at least in my sup installation. It also seems like
booleans *must* be in ALLCAPS to be recognized.

Thus:

NOT label:mylabel   - gives a syntax error
not label:mylabel   - is 'not OR label:mylabel' [searching for the word
                        "not" or for the label]

I'm getting some results from a search on 'label: NOT label:mylabel',
though I'm not sure if the results I'm getting are correct for what
you're looking for.

[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

[-- Attachment #2: Type: text/plain, Size: 140 bytes --]

_______________________________________________
sup-talk mailing list
sup-talk@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-talk

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2010-08-09 20:31 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-08-05  2:14 [sup-talk] searches Brian May
2010-08-05 13:49 ` John Bent
2010-08-05 14:25   ` Gregor Hoffleit
2010-08-09  5:59     ` Brian May
2010-08-09 20:19       ` Marc Hartstein
2010-08-05 14:35 ` Mark Alexander

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox