Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitc16f746

Browse files
committed
[PGPRO-5113] Added extra conditions for using tuple map (v9.6 - v11)
1 parent6e155ce commitc16f746

File tree

1 file changed

+13
-1
lines changed

1 file changed

+13
-1
lines changed

‎src/partition_filter.c

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -929,7 +929,19 @@ partition_filter_exec(CustomScanState *node)
929929
if (rri_holder->tuple_map||
930930
(!junkfilter&&
931931
(state->command_type==CMD_INSERT||state->command_type==CMD_UPDATE)&&
932-
(slot->tts_tupleDescriptor->natts>rri->ri_RelationDesc->rd_att->natts/* extra fields */)))
932+
(slot->tts_tupleDescriptor->natts>rri->ri_RelationDesc->rd_att->natts/* extra fields */
933+
#ifPG_VERSION_NUM<120000
934+
/*
935+
* If we have a regular physical tuple 'slot->tts_tuple' and
936+
* it's locally palloc'd => we will use this tuple in
937+
* ExecMaterializeSlot() instead of materialize the slot, so
938+
* need to check number of attributes for this tuple:
939+
*/
940+
|| (slot->tts_tuple&&slot->tts_shouldFree&&
941+
HeapTupleHeaderGetNatts(slot->tts_tuple->t_data)>
942+
rri->ri_RelationDesc->rd_att->natts/* extra fields */)
943+
#endif
944+
)))
933945
{
934946
#ifPG_VERSION_NUM<120000
935947
HeapTuplehtup_old,

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp