A hint, or a GUC hint, specifies a configuration parameter value when a plan is generated.
set [global](guc_name guc_value)
Currently, GUC hints support only some configuration parameters. Some parameters cannot be configured at the subquery level and can only be configured at the statement level. The following table lists the supported parameters.
Parameter |
Configured at the Subquery Level (Yes/No) |
---|---|
agg_redistribute_enhancement |
Yes |
best_agg_plan |
Yes |
cost_model_version |
No |
cost_param |
No |
enable_bitmapscan |
Yes |
enable_broadcast |
Yes |
enable_extrapolation_stats |
Yes |
enable_fast_query_shipping |
No |
enable_force_vector_engine |
No |
enable_hashagg |
Yes |
enable_hashjoin |
Yes |
enable_index_nestloop |
Yes |
enable_indexscan |
Yes |
enable_join_pseudoconst |
Yes |
enable_nestloop |
Yes |
enable_nodegroup_debug |
No |
enable_partition_dynamic_pruning |
Yes |
enable_sort |
Yes |
enable_vector_engine |
No |
expected_computing_nodegroup |
No |
force_bitmapand |
Yes |
from_collapse_limit |
Yes |
join_collapse_limit |
Yes |
join_num_distinct |
Yes |
qrw_inlist2join_optmode |
Yes |
qual_num_distinct |
Yes |
query_dop |
No |
rewrite_rule |
No |
skew_option |
Yes |
Hint the query plan in Examples as follows:
explain select /*+ set global(query_dop 0) */ i_product_name product_name ...
This hint indicates that the query_dop parameter is set to 0 when the plan for a statement is generated, which means the SMP adaptation function is enabled. The generated plan is as follows: