Re: Two perceived query language imbalances

Subject: Re: Two perceived query language imbalances

Date: Fri, 23 Apr 2021 09:12:34 -0300

To: Alexander Adolf, notmuch@notmuchmail.org

Cc:

From: David Bremner


Alexander Adolf <alexander.adolf@condition-alpha.com> writes:

>
> Any technical reason for "from" having a regex search, but "to" not?

Yes, it is purely technical. The regex support relies on the existence
of a Xapian value slot for the field in question. It isn't clear what
the time / space impact of adding another value slot would be. It is
probably not unbearable, but someone needs to do the tests.

>> id:<message-id> or mid:<message-id> or mid:/<regex>/
>>        For id: and mid:, message ID values are the literal contents of
>>        the Message-ID: header of email messages, but without the '<',
>>        '>' delimiters.
>
> Similar thing here: "id:" and "mid:" can be used interchangeably, except
> for regex search. Adding "id:/regex/" would seem most useful to me.
>

This was intentional, to avoid breaking existing scripts / internals
that rely on treating id: as the primary key for the database. At least
that was the concensus when we added it. It seems like one answer would
be for you to just use mid: all the time, since it already has the
behaviour you like.

d
_______________________________________________
notmuch mailing list -- notmuch@notmuchmail.org
To unsubscribe send an email to notmuch-leave@notmuchmail.org

Thread: