mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-09-23 02:00:49 +00:00
add readPrefix()/readSuffix() calls for completeness #2084 [#CLICKHOUSE-3540]
This commit is contained in:
parent
88a9b7de91
commit
1be7c09702
@ -74,8 +74,13 @@ void PushingToViewsBlockOutputStream::write(const Block & block)
|
||||
BlockInputStreamPtr from = std::make_shared<OneBlockInputStream>(block);
|
||||
InterpreterSelectQuery select(view.query, *views_context, {}, QueryProcessingStage::Complete, 0, from);
|
||||
BlockInputStreamPtr data = std::make_shared<MaterializingBlockInputStream>(select.execute().in);
|
||||
|
||||
data->readPrefix();
|
||||
|
||||
while (Block result_block = data->read())
|
||||
view.out->write(result_block);
|
||||
|
||||
data->readSuffix();
|
||||
}
|
||||
catch (Exception & ex)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user