Gnus development mailing list
 help / color / mirror / Atom feed
From: Kai.Grossjohann@CS.Uni-Dortmund.DE (Kai Großjohann)
Cc: ding@gnus.org
Subject: Re: example queries for nnir
Date: Sun, 18 Jun 2000 21:27:28 +0200	[thread overview]
Message-ID: <vafn1kivlgf.fsf@lucy.cs.uni-dortmund.de> (raw)
In-Reply-To: Harry Putnam's message of "17 Jun 2000 11:21:13 -0700"

Harry Putnam <reader@newsguy.com> writes:

> A small request for nnir users with some experience, to post a few
> sample queries  using the `glimpse' or `wais' engines.
> 
> Very unfamiliar with wais here, so any examples would be very usefull.

Using the example format file given in nnir.el, there are four fields:
to, from, subject, and the global field.

The to field contains the To and Cc mail headers.  The from field
contains the From mail header.  The subject field contains the Subject
mail header.

The global field contains all of the above headers, plus the body of
each message.

Thus, the query `foo' searches for foo occuring anywhere in the body
or in the above mentioned header fields.  `from=miller' searches for
`miller' in the From header.  `to=smith' searches for `smith' in the
To and Cc headers.  I think you can see what `subject=bla' does...

If you want to search for several words, you can say `to=(smith and
miller)' to search for messages which were sent to both people at the
same time.  `to=(smith or miller)' finds messages sent to smith, as
well as messages sent to miller, as well as messages sent to both
smith and miller.

Due to ranking, messages sent to both smith and miller have a higher
score than messages sent to only smith or only miller.  The score is
that four-digit number in the beginning of the subject header.

Since `or' is the default, you can say `to=(smith miller)' instead of
`to=(smith or miller)'.

You can also combine searching in several fields, such as

    from=miller and subject=hungry and blarfl

Here, a matching mail must be from miller, and `hungry' must be in the
subject header, and `blarfl' must be somewhere in the body (or in the
From, To, Cc, Subject header).

> Glimpse queries can be difficult since glimpse doesn't allow full
> regexp in the actual query string.
> 
> This can make something like searching for a subject where you don't
> know the full string difficult since ^Subject:.*KEYWORDS won't work.

It doesn't?  The documentation seems to say it should.  Does
`^Subject:#KEYWORD' do anything useful?

Oh, now I see that the documentation doesn't mention `^', so that's
why it doesn't work.  But does `Subject:#KEYWORD' work?

`#' seems to be an abbrev for `.*'.

> An example that can be confusing is(from nnir.el):
> 
> ;; . . . . . . . . . . . . . . . . . . . . . . . . . . . . The
> ;; second variable to set is `nnir-search-engine'.  Choose one of the
> ;; engines listed in `nnir-engines'.

I have now included an explicit pointer to the variable
documentation.  I have also tried to beef up the documentation for
nnir-engines.  Did it help?  New version on ftp server,
ftp://ls6-ftp.cs.uni-dortmund.de/pub/src/emacs/

> Showing some example settings would be a little less confusing.

Right.  Hm.  I'll do that.

> A final query.. Does anyone know of a search tool that uses a database
> but also allows full regexp use in the queries?  This seems to be
> mutually exclusive, or something.

Normal search engines build a word-based index, and when they see a
query for the word foo, they look in the index for all documents
containing that word.  This approach does not really play ball with
full-blown regular expressions...

For regular expressions, you would have to scan each document in
succession, and with multi-gigabyte databases, this is just much too
slow.

But it does appear that Glimpse tries to strike a balance between
added efficiency due to indexes and the power of regular expressions.

kai
-- 
I like BOTH kinds of music.



  reply	other threads:[~2000-06-18 19:27 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-06-17 18:21 Harry Putnam
2000-06-18 19:27 ` Kai Großjohann [this message]
2000-06-18 20:31   ` Harry Putnam
2000-06-18 22:25     ` Kai Großjohann
2000-06-19  0:18       ` Harry Putnam
2000-06-20 11:29   ` Harry Putnam
2000-06-20 16:30     ` Kai Großjohann
2000-06-20 23:32       ` Harry Putnam
2000-06-23 12:33         ` Kai Großjohann
2000-06-23 23:50           ` Harry Putnam
2000-06-24 19:36             ` Kai Großjohann
2000-06-24 23:23               ` Harry Putnam
2000-06-25  7:22               ` Norbert Koch
2000-07-19  4:11           ` Harry Putnam

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=vafn1kivlgf.fsf@lucy.cs.uni-dortmund.de \
    --to=kai.grossjohann@cs.uni-dortmund.de \
    --cc=ding@gnus.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).