From: Michal Nazarewicz <mina86@mina86.com>
To: Jani Nikula <jani@nikula.org>,
notmuch@notmuchmail.org, David Bremner <david@tethera.net>
Subject: Re: [PATCH v3 6/9] lib: add date range query support
Date: Thu, 13 Sep 2012 13:14:37 +0200 [thread overview]
Message-ID: <xa1tsjamdvj6.fsf@mina86.com> (raw)
In-Reply-To: <532340d05ea748518c021048900bb83149e04e88.1347484177.git.jani@nikula.org>
[-- Attachment #1: Type: text/plain, Size: 1716 bytes --]
On Wed, Sep 12 2012, Jani Nikula wrote:
> Add a custom value range processor to enable date and time searches of
> the form date:since..until, where "since" and "until" are expressions
> understood by the previously added date/time parser, to restrict the
> results to messages within a particular time range (based on the Date:
> header).
>
> If "since" or "until" describes date/time at an accuracy of days or
> less, the values are rounded according to the accuracy, towards past
> for "since" and towards future for "until". For example,
> date:november..yesterday would match from the beginning of November
> until the end of yesterday. Expressions such as date:today..today
> means since the beginning of today until the end of today.
IMO this is totally unintuitive and not how the range should work.
date:foo..bar should return messages whose date >= foo and < bar. So
for instance date:november..yesterday should return messages whose date
is > 2012/11/01 00:00:00 and < 2012/09/12 00:00:00. So to get
yesterdays messages one would do: date:yesterday..today.
> Open-ended ranges are supported (since Xapian 1.2.1), i.e. you can
> specify date:..until or date:since.. to not limit the start or end
> date, respectively.
>
> CAVEATS:
>
> Xapian does not support spaces in range expressions. You can replace
> the spaces with '_', or (in most cases) '-', or (in some cases) leave
> the spaces out altogether.
--
Best regards, _ _
.o. | Liege of Serenely Enlightened Majesty of o' \,=./ `o
..o | Computer Science, Michał “mina86” Nazarewicz (o o)
ooo +----<email/xmpp: mpn@google.com>--------------ooO--(_)--Ooo--
[-- Attachment #2.1: Type: text/plain, Size: 0 bytes --]
[-- Attachment #2.2: Type: application/pgp-signature, Size: 835 bytes --]
next prev parent reply other threads:[~2012-09-13 11:14 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-09-12 21:27 [PATCH v3 0/9] notmuch search date:since..until query support Jani Nikula
2012-09-12 21:27 ` [PATCH v3 1/9] build: drop the -Wswitch-enum warning Jani Nikula
2012-09-12 21:27 ` [PATCH v3 2/9] parse-time-string: add a date/time parser to notmuch Jani Nikula
2012-09-13 11:10 ` Michal Nazarewicz
2012-09-13 12:07 ` Jani Nikula
2012-09-17 14:13 ` Michal Nazarewicz
2012-09-17 15:54 ` Jani Nikula
2012-09-13 12:48 ` Tomi Ollila
2012-09-25 11:56 ` Michal Sojka
2012-10-03 18:49 ` Jani Nikula
2012-10-03 19:02 ` Michal Sojka
2012-09-12 21:27 ` [PATCH v3 3/9] test: add new test tool parse-time for date/time parser Jani Nikula
2012-09-12 21:27 ` [PATCH v3 4/9] test: add smoke tests for the date/time parser module Jani Nikula
2012-09-25 12:05 ` [PATCH] test: Improve " Michal Sojka
2012-10-03 20:32 ` Jani Nikula
2012-10-04 11:02 ` Michal Sojka
2012-09-12 21:27 ` [PATCH v3 5/9] build: build parse-time-string as part of the notmuch lib and static cli Jani Nikula
2012-09-12 21:27 ` [PATCH v3 6/9] lib: add date range query support Jani Nikula
2012-09-13 11:14 ` Michal Nazarewicz [this message]
2012-09-13 11:32 ` Tomi Ollila
2012-09-13 13:33 ` Jani Nikula
2012-09-17 15:11 ` Michal Nazarewicz
2012-09-13 12:32 ` David Bremner
2012-09-17 15:03 ` Michal Nazarewicz
2012-09-17 15:35 ` Tomi Ollila
2012-09-17 16:10 ` David Bremner
2012-09-25 12:15 ` Michal Sojka
2012-09-12 21:27 ` [PATCH v3 7/9] test: add tests for date:since..until range queries Jani Nikula
2012-09-12 21:27 ` [PATCH v3 8/9] man: document the " Jani Nikula
2012-09-12 21:27 ` [PATCH v3 9/9] NEWS: date range search support Jani Nikula
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
List information: https://notmuchmail.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=xa1tsjamdvj6.fsf@mina86.com \
--to=mina86@mina86.com \
--cc=david@tethera.net \
--cc=jani@nikula.org \
--cc=notmuch@notmuchmail.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.
Code repositories for project(s) associated with this public inbox
https://yhetil.org/notmuch.git/
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 read-only IMAP folder(s) and NNTP newsgroup(s).