There are operators ":" and "." for operations with lists of objects "data-" in the system.
":" - direct link
"." - backward link
Result of each operation - list of objects.
During work with lists operators "+", "-", "/", "*" are supported. Their work is identical to operations with aggregates.
You can sum, deduct, divide and multiply them.
When you sum lists (+) the result list contains all elements from the first and the second lists without doubling.
When you deduct (-) the second list from the first list the result list contains information from the first list without elements from the second list.
When you divide (/) the result list contains elements only from the first list or only from the second list.
When you multiply (*) the result list contains elements from the both lists.
It is possible to use brackets "(" and ")" in expressions.
list contains all files with extensions "mes" and "mes2" from the folder "guestbook".
Here is one more operator for list processing - "!"
It's used for operations ":" and "." iteration.
For example, record "data-guestbook:mes!" equals to sequence: "data-guestbook:mes+data-guestbook:mes:mes+..."
We use it for opinion quantity calculation for example.
At first we'll get an opinions on the message "1.mes".
Then opinions on the opinions on this message, etc.
If opinions would be presented in the form of tree, operation ":reply!" get list of all elements from that tree.
We use parameter "sort" to sort the list. It is similarly to parameters "skip" and "on_page" (see section 4)
List is sorted in alphabetical order by the default.
Record format: list?sort=template
Template "val_tpl" contents: <&$1?Value>.
The result is file sorting with extension "mes" according to its contents
(numerical or string).
Template "val/#1" would be called for every object. Sorting would be processed by finding during template processing values.
Parameter "desc" is used for sorted list output in postorder.
Parameter "where=template" is used for fetching.
Sequence includes object if the result of template "/#1" processing is nonzero and nonempty.
Note, there are parameters "?Pos(object)", "?Next(object)" and "?Prev(object)". It returns object position, next object and previous object in the list accordingly.
If there are two objects with extension "mes": "1.mes" and "2.mes". Then the result of expression is "2".