Return-Path: X-Original-To: notmuch@notmuchmail.org Delivered-To: notmuch@notmuchmail.org Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id 6C6F1429E20 for ; Thu, 24 Mar 2011 06:50:29 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: 0 X-Spam-Level: X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id QrBGHL-P-h05 for ; Thu, 24 Mar 2011 06:50:27 -0700 (PDT) Received: from max.feld.cvut.cz (max.feld.cvut.cz [147.32.192.36]) by olra.theworths.org (Postfix) with ESMTP id 0DDC7431FB5 for ; Thu, 24 Mar 2011 06:50:27 -0700 (PDT) Received: from localhost (unknown [192.168.200.4]) by max.feld.cvut.cz (Postfix) with ESMTP id 1A52919F33A9; Thu, 24 Mar 2011 14:50:25 +0100 (CET) X-Virus-Scanned: IMAP AMAVIS Received: from max.feld.cvut.cz ([192.168.200.1]) by localhost (styx.feld.cvut.cz [192.168.200.4]) (amavisd-new, port 10044) with ESMTP id eu7faEDoystm; Thu, 24 Mar 2011 14:50:23 +0100 (CET) Received: from imap.feld.cvut.cz (imap.feld.cvut.cz [147.32.192.34]) by max.feld.cvut.cz (Postfix) with ESMTP id C88963CFE7C; Thu, 24 Mar 2011 14:50:22 +0100 (CET) Received: from steelpick.2x.cz (note-sojka.felk.cvut.cz [147.32.86.30]) (Authenticated sender: sojkam1) by imap.feld.cvut.cz (Postfix) with ESMTPSA id 5AE17FA008; Thu, 24 Mar 2011 14:50:21 +0100 (CET) Received: from wsh by steelpick.2x.cz with local (Exim 4.72) (envelope-from ) id 1Q2kvd-00014i-6B; Thu, 24 Mar 2011 14:50:21 +0100 From: Michal Sojka To: Austin Clements Subject: Re: Date ranges syntax (was: Xapian locking errors with custom query parser) In-Reply-To: References: <87d3nhe3g9.fsf@steelpick.2x.cz> <87lj0m8ki5.fsf@yoom.home.cworth.org> <20110311024730.GA31011@mit.edu> <8762rq8byr.fsf@yoom.home.cworth.org> <87k4g6vxrw.fsf@steelpick.2x.cz> User-Agent: Notmuch/0.5-103-g1253785 (http://notmuchmail.org) Emacs/23.2.1 (x86_64-pc-linux-gnu) Date: Thu, 24 Mar 2011 14:50:21 +0100 Message-ID: <87mxkksk4i.fsf@steelpick.2x.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: notmuch@notmuchmail.org X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Mar 2011 13:50:29 -0000 On Mon, 21 Mar 2011, Austin Clements wrote: > On Fri, Mar 11, 2011 at 3:58 AM, Michal Sojka wrote: > > Additionally, I'd suggest to support value range queries for dates with > > ".." syntax. Besides that some users may relay on this syntax, I use > > date searches a lot and with custom query parser I have to type > > "after:yesterday", which is unnecessarily long. I wish that > > "yesterday..", which is much easier to type, would do the same. > > Similarly, "mon..wed" would be easier to type than "after:mon > > before:wed". What do you think? > > Personally, I just don't understand the .. range syntax, which is why > I left it out (also, I was following the example in the TODO file). > It's completely inconsistent with the rest of the query syntax and > makes no indication of what it's a range over (what if you had other > ordinal values to search over? what if you could search by the > received date or the sent date?). > > What about something like "date:mon..wed"? That's consistent with the > query syntax (the range part becomes part of the date syntax, not part > of the top-level query syntax), it indicates the domain of the search > term in a clean and extensible way, and it's succinct. Yes, the date prefix with ranges in value sounds reasonable and the word "date" is even shorter than "after" or "before". -Michal