2014-04-10 18:56:51 +00:00
created: 20140410103123179
2017-01-03 18:01:56 +00:00
modified: 20170103175939836
2015-01-18 18:39:00 +00:00
tags: [[Filter Operators]] [[Group Operators]]
title: each Operator
2014-04-10 18:56:51 +00:00
type: text/vnd.tiddlywiki
2015-01-18 18:39:00 +00:00
caption: each
2015-02-03 19:29:25 +00:00
op-purpose: select one of each group of input titles by field
op-input: a [[selection of titles|Title Selection]]
2018-08-19 17:37:37 +00:00
op-suffix: optionally, `list-item` or `value`
2015-02-03 19:29:25 +00:00
op-parameter: the name of a [[field|TiddlerFields]], defaulting to <<.field title>>
op-parameter-name: F
op-output: a selection containing the first input title encountered for each distinct value of field <<.place F>>
2014-04-10 18:56:51 +00:00
2015-02-03 19:29:25 +00:00
Each input title is processed in turn. The value of field <<.place F>> in the corresponding tiddler is examined.
2015-01-24 21:18:44 +00:00
2015-01-27 20:38:30 +00:00
;each
2017-01-03 18:01:56 +00:00
:As long as the value of the field is unique (i.e. has not been encountered before), the title is appended to the output.
2015-11-13 10:07:24 +00:00
;each:list-item
2015-01-27 20:38:30 +00:00
:The value is treated as a [[title list|Title List]]. Each title in the list considered in turn. If it has not been encountered before, it is appended to the output.
2018-08-19 17:37:37 +00:00
;each:value
2018-08-20 14:31:57 +00:00
:As long as the title is unique it is appended to the output whether or not the corresponding tiddler exists.
2015-01-27 20:38:30 +00:00
2017-01-03 18:01:56 +00:00
If a tiddler does not contain field <<.place F>>, it is treated as if the value of the field were empty.
2014-04-10 18:56:51 +00:00
2015-01-18 18:39:00 +00:00
<<.operator-examples "each">>