Skip to main content.
home | support | download

Back to List Archive

Swish-E Phrase Search

From: <jmruiz(at)>
Date: Fri Feb 08 2002 - 14:38:07 GMT
Hi David,

You do not need to change swish.h. Probably, your problems
relays in the shell you are using. If you work in a UNIX system
(eg: linux) try the following:

swish-e -w ' "this is my phrase"' -f index_file

(single quote, double quote)
(The single quote ensures that the double quote is not trimmed
by the shell)

Another possibility is:

swish-e -w \"this is my phrase\" -f index_file

(escaping the ")

BTW, I am copying this message to the list. Perhaps this can
be useful for other people.


On 7 Feb 2002, at 15:04, David Ayres wrote:

> Hello Jose,
> I've been looking over some of your comments in the Swish-E discussion
> area, and I was wondering if you could clarify something for me
> regarding phrase searching--specifically, the delimiter switch in the
> swish.h file.  Currently, I find that in order to get an accurate hit
> when searching for a phrase, I have to use this syntax:
>  '"this is a phrase"'  (i.e., a single quote, double quote, the
>  phrase, 
> double quote, single quote)
> If I attempt to use just double quote marks, the target phrase does
> come up, but also hits containing just words from the phrase and not
> the phrase itself.  When using the syntax above, only the correct
> phrase returns.
> So I'm assuming I need to adjust the relevant lines in swish.h, which
> currently read:
> However, not being a Perl writer, I'm a little confused by the syntax.
> <g>  Can you advise on how I'd adjust these lines to reflect using a
> double quotation mark (") as a delimiter?
> Thanks!
> David Ayres
Received on Fri Feb 8 14:38:50 2002