This version is out of date, covering development from v4.6.0 to v4.7.1. It is maintained here only for inbound reference links from elsewhere. Jump to the current version of aTbRef. |
|
A Tinderbox Reference File : Actions & Rules : Operators : Full Operator List : count(set) | aTbRef Site Map |
count(set) |
Operator Type: | Set maths |
Operator Scope of Action: | Set |
A function count() counts the number of discrete items in the specified attribute (of set data type).
count(attribute)
The attribute argument is evaluated so can use, $attribute(note) or more complex expressions to get data - as long as the result is an attribute of the Set data type.
For example if KeyAttributes for the current note is "Color;Color2;NameFont" then the code
count($KeyAttributes)
is effectively
count(Color;Color2;NameFont)
and not surprisingly returns 3. Note that the count is not all unique values for the attribute across the whole TBX - scope is restricted to 'this' note or another nominated note. Specimen usage:
count($KeyAttributes)
count($KeyAttributes(some other note))
Up: Full Operator List | |
Previous: cos(argument) | Next: date(string) |
Licensed under Creative Commons Attribution-Noncommercial-Share Alike 3.0 License
[See aTbRef CC licence Attribution/Waiver info info]