From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nathan Neff Subject: Re: Agenda search: setting sort-order Date: Tue, 12 Jun 2018 15:07:39 -0500 Message-ID: References: Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="00000000000013c401056e776bed" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:46036) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fSpZv-0004ev-6a for emacs-orgmode@gnu.org; Tue, 12 Jun 2018 16:07:44 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fSpZu-0006Zb-4z for emacs-orgmode@gnu.org; Tue, 12 Jun 2018 16:07:43 -0400 Received: from mail-io0-x22b.google.com ([2607:f8b0:4001:c06::22b]:43946) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fSpZt-0006Yo-Te for emacs-orgmode@gnu.org; Tue, 12 Jun 2018 16:07:42 -0400 Received: by mail-io0-x22b.google.com with SMTP id t6-v6so841626iob.10 for ; Tue, 12 Jun 2018 13:07:41 -0700 (PDT) In-Reply-To: List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: emacs-orgmode --00000000000013c401056e776bed Content-Type: text/plain; charset="UTF-8" Bumping this question to see if anyone has a workaround - I recently have been wishing to search for keywords and order the results in reverse timestamp order. This sounds like a fairly useful and common feature, so I think there must be something I'm configuring incorrectly. I am able to reproduce the problem using a fairly clean Emacs install (a VM with no customizations). Thanks, --Nate On Wed, May 30, 2018 at 4:57 PM, Nathan Neff wrote: > Hi all, > > I'm using org-mode version 9.1.13 from elpa, and > have a custom agenda command: > > > (setq org-agenda-custom-commands > '( > ("z" search "" > ((org-agenda-sorting-strategy '(timestamp-up)))))) > > And I have an org-file with this data: > > * TODO [#C] Test1 > :foo: > <2018-04-24 Tue 19:30> > * TODO [#A] Test2 > :foo: > <2018-05-24 Thu 19:30> > * TODO [#B] Test3 > :foo: > <2017-12-24 Sun 23:33> > > The data is not sorted according to timestamp. I cannot seem to > get the data sorted in any fashion when using the "search" agenda mode. > > However, if I change "search" to "tags" and search for the "foo" tag, then > it appears that the sorting works. I've tested it with priority and > timestamp > using the above data and it sorts the items correctly. > > Why is my "search" agenda command ignoring the org-agenda-sorting-strategy? > > Thanks, > --Nate > --00000000000013c401056e776bed Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Bumping this question to see if anyone has a workaround -<= div>I recently have been wishing to search for keywords and order
the results in reverse timestamp order. =C2=A0

Th= is sounds like a fairly useful and common feature, so I think=C2=A0
there must be something I'm configuring incorrectly.=C2=A0 I am able= =C2=A0
to reproduce the problem using a fairly clean Emacs instal= l (a=C2=A0
VM with no customizations).

T= hanks,
--Nate



On Wed, May 30, 2018 at 4:5= 7 PM, Nathan Neff <nathan.neff@gmail.com> wrote:
Hi all,

I= 9;m using org-mode version 9.1.13 from elpa, and
have a custom ag= enda command:


(setq org-agenda= -custom-commands
=C2=A0 =C2=A0'(
=C2=A0 =C2=A0 =C2= =A0("z" search ""=C2=A0
=C2=A0 =C2=A0 =C2=A0 = =C2=A0((org-agenda-sorting-strategy '(timestamp-up))))))

And I have an org-file with this data:

* TODO [#C] Test1 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 :foo:=
<2018-04-24 Tue 19:30>
* TODO [#A] Test2 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 :foo:
<2018-05-24 Thu 19:30= >
* TODO [#B] Test3 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 := foo:
<2017-12-24 Sun 23:33>

= The data is not sorted according to timestamp.=C2=A0 I cannot seem to=C2=A0=
get the data sorted in any fashion when using the "search&q= uot; agenda mode.

However, if I change "searc= h" to "tags" and search for the "foo" tag, then
it appears that the sorting works.=C2=A0 I've tested it with pr= iority and timestamp
using the above data and it sorts the items = correctly.

Why is my "search" agenda com= mand ignoring the org-agenda-sorting-strategy?

Tha= nks,
--Nate

--00000000000013c401056e776bed--