mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-26 01:22:04 +00:00
Basic implementation
This commit is contained in:
parent
5cb04155d7
commit
2868bbcb21
@ -43,13 +43,14 @@ public:
|
||||
IColumn & result_data = result_col->getData();
|
||||
IColumn::Offsets & result_offsets = result_col->getOffsets();
|
||||
|
||||
result_data.reserve(input_rows_count * 10);
|
||||
result_offsets.resize(input_rows_count);
|
||||
// todo
|
||||
// result_data.reserve();
|
||||
// result_offsets.resize();
|
||||
|
||||
IColumn::Offset current_offset = 0;
|
||||
for (size_t i = 0; i < input_rows_count; ++i)
|
||||
{
|
||||
const auto flatten_data = flatten(arg_data, current_offset, arg_offsets[i]);
|
||||
const auto & flatten_data = flatten(arg_data, current_offset, arg_offsets[i]);
|
||||
result_data.insertRangeFrom(flatten_data, 0, flatten_data.size());
|
||||
current_offset += flatten_data.size();
|
||||
result_offsets[i] = current_offset;
|
||||
@ -66,7 +67,7 @@ private:
|
||||
|
||||
bool addField(DataTypePtr type_res, const Field & f, Array & arr) const;
|
||||
|
||||
const ColumnArray flatten(const IColumn & /*data*/, size_t /*from*/, size_t /*to*/) const
|
||||
const ColumnArray & flatten(const IColumn & /*data*/, size_t /*from*/, size_t /*to*/) const
|
||||
{
|
||||
// todo
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user