Zettelmarkup: Query Transclusion

00001007031140 · Info · (manual) · #manual #search #zettelmarkup #zettelstore

A query transclusion is specified by the following sequence, starting at the first position in a line: {{{query:query-expression}}}. The line must literally start with the sequence {{{query:. Everything after this prefix is interpreted as a query expression.

When evaluated, the query expression is evaluated, often resulting in a list of links to zettel, matching the query expression. The result replaces the query transclusion element.

For example, to include the list of all zettel with the all-tags #search, ordered by title specify the following query transclude element:

{{{query:all-tags:#search ORDER title}}}

This will result in:

For example, this allows to create a dynamic list of zettel inside a zettel, maybe to provide some introductory text followed by a list of child zettel.

The query will deliver only those zettel, which the current user is allowed to read.

In the above example, the action list is empty. This leads to the described list of zettel.

The following actions are supported, parameter and aggregate actions:

N (or any word that starts with N (parameter)
The resulting list will be a numbered list.
MINn (parameter)
Emit only those values with at least n aggregated values. n must be a positive integer, MIN must be given in upper-case letters.
MAXn (parameter)
Emit only those values with at most n aggregated values. n must be a positive integer, MAX must be given in upper-case letters.
TITLE (parameter)
All words following TITLE are joined together to form a title. It is used for the RSS action.
RSS (aggregate)
Transform the zettel list into an RSS 2.0➚-conformant document. The document is embedded into the referencing zettel.
Any metadata key of type Word, WordSet, or TagSet (aggregates)
Emit an aggregate of the given metadata key. The key can be given in any letter case.
{{{query:all-tags:#search | all-tags}}}

This in a tag cloud of all tags that are used together with the tag #search:
https://zettelstore.de/manual/h/00001007031140
zettelstore.de
crawl=CC-MAIN-2022-40
7160
application/http; msgtype=response
sha1:RPTAR3HDDICLSKI73TSAYGSWE2AOG7LK
<urn:uuid:60ae4e8a-cac5-490f-aacc-469b3a8422fb>
2022-09-25T17:33:21Z
217.160.171.109
text/html
sha1:QBIUOOZLWAGMS2TPXWPGL6JKY2ZOKGWX
<urn:uuid:4ffa822d-9021-4611-8591-8d06500aeb16>
https://zettelstore.de/manual/h/00001007031140
response
<urn:uuid:46d508f2-c586-48cc-92a4-c73faf28bf05>
isPartOf: CC-MAIN-2022-40
publisher: Common Crawl
description: Wide crawl of the web for September/October 2022
operator: Common Crawl Admin (info@commoncrawl.org)
hostname: ip-10-67-67-36
software: Apache Nutch 1.19 (modified, https://github.com/commoncrawl/nutch/)
robots: checked via crawler-commons 1.4-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)
format: WARC File Format 1.1
conformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/