Nonstop Database, HiRDB Version 9 UAP Development Guide
The following optimization methods affect grouping processing:
If the HiRDB system judges that sort and hash processing for grouping are unnecessary, it selects a method that can process the data faster. For details about grouping processing, see the HiRDB Version 9 Command Reference manual.
The following table describes the optimization features related to grouping processing methods.
Table 4-9 Optimization features related to grouping processing methods
Optimization method (type of grouping processing method) | Advantages | Disadvantages |
---|---|---|
Omitted (FLOATABLE SORT) | Data can be searched rapidly if the data count values are unevenly distributed among the back-end servers and grouping does not reduce the data count. | If the group count is small and the data count is high, the performance drops because the communication volume increases. |
Rapid grouping processing (HASH) | Data can be searched rapidly when the group count is small. | If the group count is large, the performance drops because the data is grouped by hashing. |
Group processing, ORDER BY processing, and DISTINCT set function processing at the local back-end server (LIST SORT) | Data can be searched rapidly if grouping substantially decreases the data count. Data can also be searched rapidly if the data is grouped by partitioning keys. | If the data count values are unevenly distributed among the back-end servers because of sorting in each back-end server, the performance drops because processing takes a long time in servers that have a high data count. |
The following figure shows grouping processing when the optimization method is omitted.
Figure 4-22 Grouping processing method when the optimization method is omitted
The following figure shows grouping processing when rapid grouping processing is applied.
Figure 4-23 Grouping processing when rapid grouping processing is applied
The following figure shows grouping processing when group processing, ORDER BY processing, and DISTINCT set function processing are applied at the local back-end server. However, this diagram shows the processing when one table is searched.
Figure 4-24 Grouping processing when group processing, ORDER BY processing, and DISTINCT set function processing are applied at the local back-end server
All Rights Reserved. Copyright (C) 2011, Hitachi, Ltd.