Chao LU <[email protected]> writes:
> Dear all,
>
> I'm trying to figure out how to do Properties search by define an
> agenda command.
>
> Here is my item in org file:
>
> *** Franz Schwabl / Quantum Mechanics
> :PROPERTIES:
> :TITLE: Quantum Mechanics
> :AUTHOR: Franz Schwabl
> :CATEGORY: Quantum Mechanics
> :TAGS: Quantum Mechanics, Group Theory
> :KEYWORD: Quantum Mechanics, Perturbation, Second Quantization
> :LOCATION: iTune
> :END:
>
> And I want to define a agenda command to search this item out. I've
> tried this one, but did not work:
> ("19" "TEST" occur-tree "Title="Quantum Mechanics"")
> ("19" "TEST" tags "Title="Quantum Mechanics"")
>
> So is there anyone knows how to do this correctly?
Two things:
1. You need to escape the inner quote marks in the custom command.
2. AFAICT Properties are case sensitive. Your drawer includes a "TITLE"
property but your custom command searches for "Title".
This custom command worked for me:
(setq org-agenda-custom-commands
'(("x" "TEST" tags "TITLE=\"Quantum Mechanics\"")))
You could also just type the following:
C-a m TITLE="Quantum Mechanics"
Note: you can also use regexps in property searches. E.g.,
C-a m TITLE={quantum.*mechanics}
Best,
Matt
_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
[email protected]
http://lists.gnu.org/mailman/listinfo/emacs-orgmode