Re: Searching for an Exact Email Address

Subject: Re: Searching for an Exact Email Address

Date: Sun, 02 Feb 2020 10:05:41 -0500

To: David Bremner, Teemu Likonen, notmuch@notmuchmail.org

Cc:

From: Kevin Foley


David Bremner <david@tethera.net> writes:

> Also useful is setting NOTMUCH_DEBUG_QUERY in the environment. This will
> show the parsed Xapian query. In my case this shows both
> 'to:"example@email.com"' and to:"example@email.com" end up parsed the
> same way, so I guess the problem is elsewhere.

I should have mentioned that I tried using NOTMUCH_DEBUG_QUERY with many
different quoting variations and kept getting the same final query:

Query((Tmail AND (XTOexample@1 PHRASE 3 XTOemail@2 PHRASE 3 XTOcom@3)))

It looks like the punctuation is being stripped; I get the same final
query for `notmuch search 'to:"example email com"'`.  Is this the
expected behavior?

David Bremner <david@tethera.net> writes:

>  You can also do regex searches, although they are are measurably
>  slower. The syntax is also discussed in notmuch-search-terms(7).

I tried this as well but per notmuch-search-terms(7) it looks like regex
isn't supported for the "to" field.

Also as a side note, I don't think the quoting is necessary as per the
"searching" documentation [0], "... e-mail addresses are also treated as
phrases.".

Kevin

[0] https://notmuchmail.org/searching/
_______________________________________________
notmuch mailing list
notmuch@notmuchmail.org
https://notmuchmail.org/mailman/listinfo/notmuch

Thread: