Skip to content

Commit

Permalink
[GLUTEN-3908][CH]Improve insert range selective for column nullable (C…
Browse files Browse the repository at this point in the history
…lickHouse#472)

(cherry picked from commit b8dfba5)
(cherry picked from commit 86b5622)
(cherry picked from commit 87ef298)
(cherry picked from commit b08ae0a)
(cherry picked from commit 0e1242e)
  • Loading branch information
KevinyhZou authored and baibaichen committed Jan 14, 2024
1 parent ee780a2 commit 24689b1
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions src/Columns/ColumnNullable.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -249,16 +249,8 @@ void ColumnNullable::insertRangeFrom(const IColumn & src, size_t start, size_t l
void ColumnNullable::insertRangeSelective(const IColumn & src, const IColumn::Selector & selector, size_t selector_start, size_t length)
{
const ColumnNullable & nullable_col = static_cast<const ColumnNullable &>(src);
getNullMapColumn().insertRangeSelective(*nullable_col.null_map, selector, selector_start, length);
getNestedColumn().insertRangeSelective(*nullable_col.nested_column, selector, selector_start, length);

if (!memoryIsZero(nullable_col.getNullMapData().data(), 0, nullable_col.size()))
{
getNullMapColumn().insertRangeSelective(*nullable_col.null_map, selector, selector_start, length);
}
else
{
getNullMapColumn().insertManyDefaults(length);
}
}

void ColumnNullable::insert(const Field & x)
Expand Down

0 comments on commit 24689b1

Please sign in to comment.