Skip to content

Commit 8b67e3c

Browse files
committed
Adjust various references to GEQO being non-deterministic.
It's still non-deterministic in some sense ... but given fixed settings and identical planning problems, it will now always choose the same plan, so we probably shouldn't tar it with that brush. Per bug #6565 from Guillaume Cottenceau. Back-patch to 9.0 where the behavior was fixed.
1 parent be9aad6 commit 8b67e3c

File tree

1 file changed

+8
-7
lines changed

1 file changed

+8
-7
lines changed

doc/src/sgml/config.sgml

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2427,8 +2427,7 @@ SET ENABLE_SEQSCAN TO OFF;
24272427
planning using heuristic searching. This reduces planning time for
24282428
complex queries (those joining many relations), at the cost of producing
24292429
plans that are sometimes inferior to those found by the normal
2430-
exhaustive-search algorithm. Also, GEQO's searching is randomized and
2431-
therefore its plans may vary nondeterministically.
2430+
exhaustive-search algorithm.
24322431
For more information see <xref linkend="geqo">.
24332432
</para>
24342433

@@ -2467,9 +2466,11 @@ SET ENABLE_SEQSCAN TO OFF;
24672466
this many <literal>FROM</> items involved. (Note that a
24682467
<literal>FULL OUTER JOIN</> construct counts as only one <literal>FROM</>
24692468
item.) The default is 12. For simpler queries it is usually best
2470-
to use the deterministic, exhaustive planner, but for queries with
2471-
many tables the deterministic planner takes too long, often
2472-
longer than the penalty of executing a suboptimal plan.
2469+
to use the regular, exhaustive-search planner, but for queries with
2470+
many tables the exhaustive search takes too long, often
2471+
longer than the penalty of executing a suboptimal plan. Thus,
2472+
a threshold on the size of the query is a convenient way to manage
2473+
use of GEQO.
24732474
</para>
24742475
</listitem>
24752476
</varlistentry>
@@ -2681,7 +2682,7 @@ SELECT * FROM parent WHERE key = 2400;
26812682

26822683
<para>
26832684
Setting this value to <xref linkend="guc-geqo-threshold"> or more
2684-
may trigger use of the GEQO planner, resulting in nondeterministic
2685+
may trigger use of the GEQO planner, resulting in non-optimal
26852686
plans. See <xref linkend="runtime-config-query-geqo">.
26862687
</para>
26872688
</listitem>
@@ -2716,7 +2717,7 @@ SELECT * FROM parent WHERE key = 2400;
27162717

27172718
<para>
27182719
Setting this value to <xref linkend="guc-geqo-threshold"> or more
2719-
may trigger use of the GEQO planner, resulting in nondeterministic
2720+
may trigger use of the GEQO planner, resulting in non-optimal
27202721
plans. See <xref linkend="runtime-config-query-geqo">.
27212722
</para>
27222723
</listitem>

0 commit comments

Comments
 (0)