Skip to content

Commit

Permalink
[fix](serde)fix bug in DataTypeNullableSerDe.deserialize_column_from_…
Browse files Browse the repository at this point in the history
…fixed_json
  • Loading branch information
hubgeter committed Jul 29, 2024
1 parent 11b332f commit c0034cf
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions be/src/vec/data_types/serde/data_type_nullable_serde.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -138,8 +138,10 @@ Status DataTypeNullableSerDe::deserialize_column_from_fixed_json(
auto& null_map = col.get_null_map_data();
auto& nested_column = col.get_nested_column();

null_map.resize_fill(
rows, null_map.back()); // data_type_nullable::insert_column_last_value_multiple_times()
uint8_t val = null_map.back();
size_t new_sz = null_map.size() + rows - 1;
null_map.resize_fill(new_sz,
val); // data_type_nullable::insert_column_last_value_multiple_times()
if (rows - 1 != 0) {
nested_serde->insert_column_last_value_multiple_times(nested_column, rows - 1);
}
Expand Down

0 comments on commit c0034cf

Please sign in to comment.