From mboxrd@z Thu Jan 1 00:00:00 1970 From: Richard Lawrence Subject: Agenda filtering (take 2) Date: Mon, 02 Oct 2017 13:58:24 -0700 Message-ID: <87zi99nu6n.fsf@aquinas.i-did-not-set--mail-host-address--so-tickle-me> References: <87h98194od.fsf@aquinas.i-did-not-set--mail-host-address--so-tickle-me> <871spy3rut.fsf@bzg.fr> Mime-Version: 1.0 Content-Type: text/plain; format=flowed Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:43215) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dz7nM-0005wM-2D for emacs-orgmode@gnu.org; Mon, 02 Oct 2017 16:58:32 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dz7nJ-0006cU-ET for emacs-orgmode@gnu.org; Mon, 02 Oct 2017 16:58:32 -0400 Received: from mail-pg0-x231.google.com ([2607:f8b0:400e:c05::231]:50786) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dz7nJ-0006Zf-2v for emacs-orgmode@gnu.org; Mon, 02 Oct 2017 16:58:29 -0400 Received: by mail-pg0-x231.google.com with SMTP id p5so3594377pgn.7 for ; Mon, 02 Oct 2017 13:58:27 -0700 (PDT) Received: from aquinas (c-67-169-117-151.hsd1.ca.comcast.net. [67.169.117.151]) by smtp.gmail.com with ESMTPSA id j18sm17439443pfh.161.2017.10.02.13.58.25 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 02 Oct 2017 13:58:25 -0700 (PDT) Received: from rwl by aquinas with local (Exim 4.89) (envelope-from ) id 1dz7nE-0005zN-Nq for emacs-orgmode@gnu.org; Mon, 02 Oct 2017 13:58:24 -0700 In-Reply-To: <871spy3rut.fsf@bzg.fr> 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@gnu.org Hi everyone, About a year ago, I wrote: > >> Is there a simple way for me to say to the agenda, "Show me all >> (and only) the NEXT tasks that are part of a project whose >> deadline is before (say) 2016-11-01"? It seems like this >> should be possible with the built-in agenda but I can't quite >> figure it out. The tricky thing is filtering by the deadline >> of the parent project, which might be several levels up. I'm still stuck on this, so I'd like to ask this question again. Bastien responded: > I would add a category to each project, then use something along > this: > > ("N" "My important tasks" tags-todo > "CATEGORY={cat1\\|cat2}+TODO={NEXT}+DEADLINE<=\"<+3d>\"") But that doesn't seem to work for me. The problem is that the tasks I want to list in the tags-todo search don't themselves have deadlines; only their parent projects do. I have a file with projects that look like this: ** TODO Foo University DEADLINE: <2017-11-01> *** NEXT Determine application requirements for Foo U. *** TODO Submit application I'd like to see a list of just NEXT tasks in this file, sorted by the deadline of their parent projects. I thought that property inheritance would be the way to do this. So I tried: ("jn" "Job application NEXT tasks" tags-todo "+jobmarket+application+TODO={NEXT}" ((org-use-property-inheritance t)) (org-agenda-sorting-strategy '(deadline-up)))) as well as ("jn" "Job application NEXT tasks" tags-todo "+jobmarket+application+TODO={NEXT}" ((org-use-property-inheritance '("DEADLINE")) (org-agenda-sorting-strategy '(deadline-up)))) in org-agenda-custom-commands. But neither seems to work. Can anyone provide any insights here? Is it possible for sub-tasks within a project to inherit their deadline? Many thanks as always! Best, Richard