diff --git a/sql/sql_tmp_table.cc b/sql/sql_tmp_table.cc index afb923010cfa..a8134bacf955 100644 --- a/sql/sql_tmp_table.cc +++ b/sql/sql_tmp_table.cc @@ -445,7 +445,7 @@ Field *create_tmp_field(THD *thd, TABLE *table, Item *item, Item::Type type, DBUG_ASSERT(false); break; } - if (result != nullptr) { + if (result != nullptr && thd->parallel_exec) { result->extra_length = item->pq_extra_len(group); } return result;