git.postgresql.org Git - postgresql.git/commitdiff

git projects / postgresql.git / commitdiff
? search:
summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: c442722)
Do no reset bounded before incremental sort rescan
Sat, 9 May 2020 17:41:36 +0000 (19:41 +0200)
Sat, 9 May 2020 17:41:36 +0000 (19:41 +0200)
ExecReScanIncrementalSort was resetting bounded=false, which means the
optimization would be disabled on all rescans. This happens because
ExecSetTupleBound is called before the rescan, not after it.

Author: James Coleman
Reviewed-by: Tomas Vondra
Discussion: https://postgr.es/m/20200414065336.GI1492@paquier.xyz


diff --git a/src/backend/executor/nodeIncrementalSort.c b/src/backend/executor/nodeIncrementalSort.c
index ae7ad5d7bde31fdf5e2e297fc98b9356876a1c0a..bfc2e4cf6b1d4741863375437ae440bf77985129 100644 (file)
--- a/src/backend/executor/nodeIncrementalSort.c
+++ b/src/backend/executor/nodeIncrementalSort.c
@@ -1142,7 +1142,6 @@ ExecReScanIncrementalSort(IncrementalSortState *node)
if (node->transfer_tuple != NULL)
ExecClearTuple(node->transfer_tuple);
- node->bounded = false;
node->outerNodeDone = false;
node->n_fullsort_remaining = 0;
node->bound_Done = 0;
This is the main PostgreSQL git repository.
RSS Atom

AltStyle によって変換されたページ (->オリジナル) /