SQL/MX 3.x Query Guide (H06.22+, J06.11+)

SQL/MX Operators
HP NonStop SQL/MX Query Guide640323-001
7-23
HASH_PARTIAL_GROUPBY_ROOT Operator
fragment_type .......... dp2
grouping_columns ......... DETCAT.DETSCH.T016PT1.D
HASH_PARTIAL_GROUPBY_ROOT Operator
Groupby Group
The HASH_PARTIAL_GROUPBY_ROOT operator works together as a pair with the
HASH_PARTIAL_GROUPBY_LEAF operator. The
HASH_PARTIAL_GROUPBY_ROOT operator finalizes the group by at the ESP level.
See HASH_PARTIAL_GROUPBY_LEAF Operator on page 7-22.
The HASH_PARTIAL_GROUPBY_ROOT operator has one child node. The description
field for this operator contains:
The following is an example of the HASH_PARTIAL_GROUPBY_ROOT operator:
control query shape
hash_groupby(partition_access(hash_groupby(scan)));
prepare TestQuery32 from
select d from t016pt1 group by d;
DESCRIPTION
fragment_id ............ 0
parent_frag ............ (none)
fragment_type .......... master
grouping_columns ......... DETCAT.DETSCH.T016PT1.D
Token Followed by ... Data Type
fragment_id A sequential number assigned to the fragment.
0 is always the master executor and 1 is
reserved for the EXPLAIN plan. Numbers 2 to n
will be ESP or DAM fragments.
integer
parent_frag The fragment_id for the parent of the current
fragment. The value is (none) for the master
executor.
integer
fragment_type Master, ESP, or DP2. text
aggregates Expression of the aggregate function. expr(text)
selection_predicates Expression of the HAVING clause. expr(text)
grouping_columns Expression of the grouping columns. expr(text)