IF allows for inclusion in set based on Individual Property. The format is:
IF '(' setexpression1 ',' setexpression2 ')'
There are occasions when the global nature of set selection, where each set is selected
on a global basis and the union or intersection of these sets is used to produce the
overall selection, is not appropriate because one wishes to examine the simultaneous
properties of an individual variable to determine whether it should be included in the
set. Examination of individual properties is expensive in comparison to the creation of a
global set, so the IF() function should only be used when there is no other choice.
In operation, each member of setexpression1 is placed where the NODE operator will find
it, and setexpression2 is evaluated. If the set resulting from setexpression2 is not null,
the member of setexpression1 is added to the output set.
To ensure efficiency, setexpression1 should be as restrictive as possible.
MEMBERS(a, {b, c}) MEMBERS(b, {d, e, f}) IF( recurse members a, FND( (members node), = 0))! Find the leaf nodes
The IF() function cycles through all variables which meet the requirement of being a
recursive member of a (the nodes b, c, d, e, f), setting node to each of these in turn,
then interprets the FND function.
The FND function takes the current value of node, finds its members, and if the size of
that set matches the specification, returns the set (matching to zero is a special case),
otherwise returns the null set. If FND does not return a null set, the current value of
node is included in the output set.