1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-06-30 09:13:16 +00:00
TiddlyWiki5/editions/tw5.com/tiddlers/filters/field.tid

29 lines
1.1 KiB
Plaintext
Raw Normal View History

2014-04-10 18:56:51 +00:00
created: 20140410103123179
2015-01-19 19:37:26 +00:00
modified: 20150119192437000
tags: [[Filter Operators]] [[Common Operators]] [[Field Operators]]
title: field Operator
2014-04-10 18:56:51 +00:00
type: text/vnd.tiddlywiki
caption: field
purpose: filter the input tiddlers by field value
<$macrocall $name=".operator-def-suffix"
2015-01-19 19:37:26 +00:00
input="a [[title selection|Title Selections]]"
suffix="the name of a field"
suffixName="f"
parameter="a potential value for field <<.place f>>"
paramName="p"
2015-01-19 19:37:26 +00:00
output="the [[subselection|Title Selections]] of the input tiddlers in which field <<.place f>> has the value <<.place p>>"
/>
If <<.place p>> is empty, <<.op field>> will match both of the following:
2014-04-10 18:56:51 +00:00
* tiddlers that don't contain field <<.place f>>
* tiddlers in which field <<.place f>> exists but has an empty value
2014-04-10 18:56:51 +00:00
;Negation
2015-01-19 19:37:26 +00:00
: `!field` outputs the subselection of the input tiddlers in which field <<.place f>> does <<.em not>> have the value <<.place p>>.
2014-04-10 18:56:51 +00:00
The [[Filter Syntax]] treats any unrecognised [[filter operator|Filter Operators]] as if it was the suffix to the <<.olink field>> operator. See the second example below.
2014-04-10 18:56:51 +00:00
<<.operator-examples "field">>