Sets upper bound for parallel execution of GROUP BY operations and for arms of a UNION.
Integer less than or equal to number of CPUs.
Can be set temporary, for an individual connection, or for the PUBLIC group. Takes effect immediately.
24
Sets an upper bound for parallelism the query optimizer can choose for GROUP BY operations or arms of a UNION, regardless of how many CPUs are available. This option is only effective on GROUP BY operations when the PARALLEL_GBH_UNITS option is not set. The PARALLEL_GBH_UNITS option sets a specific number for the degree of parallelism, whereas the MAX_QUERY_PARALLELISM option value is an upper limit and allows the optimizer more flexibility.
Normally you should not set this option. However, if you have more than 16 CPUs and you see excessive CPU time spent on system usage, try setting MAX_QUERY_PARALLELISM to a value less than 16. You will need to experiment with this value to determine the right setting for your platform, number of CPUs, and queries. Remember that there is some overhead involved when you distribute execution across multiple CPUs. In some configurations this overhead could actually decrease performance if parallelism is allowed across all available CPUs, while in others using all available CPUs could be beneficial.