From 4731a54c376bddd3dda04da0c95f05ff32a57f0b Mon Sep 17 00:00:00 2001 From: zadam Date: Mon, 22 Apr 2019 18:12:30 +0200 Subject: [PATCH] Updated Search (markdown) --- Search.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Search.md b/Search.md index 0e30706..a274c86 100644 --- a/Search.md +++ b/Search.md @@ -53,6 +53,12 @@ It's also possible to query by so called "virtual attributes": * `mime` - e.g. `text/html` for text note * `text` - fulltext attribute of both title and content together +### Order and limit + +It's possible to order the results by one or more attribute, e.g. `@orderBy=year,-genre` will order notes by `year` label in ascending order and then by `genre` label in descending order (because of `-` sign). + +You can also limit the number of results using e.g. `@limit=1` will return only the first result. If there's no `limit`, then all notes are returned. + ### Date comparisons Attribute values are untyped strings which means that although you can save into it any kind of value like number or date, Trilium doesn't really know what kind of value it is and can't really treat it properly.