Groups a sequence of two or more query conditions.
(ade_qrygroup condition_id1 condition_id2)
Returns T or nil.
condition_id1 | ID of first condition of the group (real) |
condition_id2 | ID of last condition of the group (real) |
This function affects the current query.
A query definition consists of a sequence of query conditions. Within such a sequence, you can define subsequences of two or more conditions by grouping them (by enclosing them in parentheses). You can group conditions when you first define the query. See the bggroups and endgroups parameters of ade_qrydefine. Or you can do it later using ade_qrygroup.
When you call ade_qrygroup, the condition you specify as the first condition of the group (condition_id1) must be a predecessor to the one you specify as the last (condition_id2). The function groups the first and the last and any conditions in between. For example, consider the following query definition, which is composed of conditions A, B, C, and D:
A AND B OR C OR D
The function call (ade_qrygroup IDofB IDofD) changes the definition to
A AND (B OR C OR D)
To ungroup queries, use ade_qryungroup.