pgsql: Fix CLUSTER on expression indexes.

Поиск
Список
Период
Сортировка
От Andres Freund
Тема pgsql: Fix CLUSTER on expression indexes.
Дата
Msg-id E1iKQtg-00049c-0N@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Fix CLUSTER on expression indexes.

Since the introduction of different slot types, in 1a0586de3657, we
create a virtual slot in tuplesort_begin_cluster(). While that looks
right, it unfortunately doesn't actually work, as ExecStoreHeapTuple()
is used to store tuples in the slot. Unfortunately no regression tests
for CLUSTER on expression indexes existed so far.

Fix the slot type, and add bare bones tests for CLUSTER on expression
indexes.

Reported-By: Justin Pryzby
Author: Andres Freund
Discussion: https://postgr.es/m/20191011210320.GS10470@telsasoft.com
Backpatch: 12, like 1a0586de3657

Branch
------
REL_12_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/6d3fe6b6bf05777cb7152b462594a1993af15857

Modified Files
--------------
src/backend/utils/sort/tuplesort.c    |   2 +-
src/test/regress/expected/cluster.out | 107 ++++++++++++++++++++++++++++++++++
src/test/regress/sql/cluster.sql      |  37 ++++++++++++
3 files changed, 145 insertions(+), 1 deletion(-)


В списке pgsql-committers по дате отправления:

Предыдущее
От: Andres Freund
Дата:
Сообщение: pgsql: Fix CLUSTER on expression indexes.
Следующее
От: Michael Paquier
Дата:
Сообщение: pgsql: Doc: Fix various inconsistencies