comparison roundup/hyperdb.py @ 6409:ce99e0d39262

Add documentation for multilink expression syntax
author Ralf Schlatterbeck <rsc@runtux.com>
date Tue, 11 May 2021 11:32:26 +0200
parents 9957d8d10783
children 66ccddb034f2
comparison
equal deleted inserted replaced
6408:ef7bc1fac35a 6409:ce99e0d39262
1699 1699
1700 This also means that for strings in exact_match_spec it doesn't 1700 This also means that for strings in exact_match_spec it doesn't
1701 make sense to specify multiple values because those cannot all 1701 make sense to specify multiple values because those cannot all
1702 be matched exactly. 1702 be matched exactly.
1703 1703
1704 For Link and Multilink properties the special ID value '-1'
1705 matches empty Link or Multilink fields. For Multilinks a postfix
1706 expression syntax using negative ID numbers (as strings) as
1707 operators is supported. Each non-negative number (or '-1') is
1708 pushed on an operand stack. A negative number pops the required
1709 number of arguments from the stack, applies the operator, and
1710 pushes the result. The following operators are supported:
1711 - -2 stands for 'NOT' and takes one argument
1712 - -3 stands for 'AND' and takes two arguments
1713 - -4 stands for 'OR' and takes two arguments
1714 Note that this special handling of ID arguments is applied only
1715 when a negative number smaller than -1 is encountered as an ID
1716 in the filter call. Otherwise the implicit OR default applies.
1717 Examples of using Multilink expressions would be
1718 - '1', '2', '-4', '3', '4', '-4', '-3'
1719 would search for IDs (1 or 2) and (3 or 4)
1720 - '-1' '-2' would search for all non-empty Multilinks
1721
1722
1704 The propname in filterspec and prop in a sort/group spec may be 1723 The propname in filterspec and prop in a sort/group spec may be
1705 transitive, i.e., it may contain properties of the form 1724 transitive, i.e., it may contain properties of the form
1706 link.link.link.name, e.g. you can search for all issues where a 1725 link.link.link.name, e.g. you can search for all issues where a
1707 message was added by a certain user in the last week with a 1726 message was added by a certain user in the last week with a
1708 filterspec of 1727 filterspec of

Roundup Issue Tracker: http://roundup-tracker.org/