columnar-sender: development [#METR-11888].

This commit is contained in:
Alexey Milovidov 2014-07-11 05:20:39 +04:00
parent 94012f8231
commit 818338872f

View File

@ -286,24 +286,12 @@ void Connection::sendData(const Block & block, const String & name)
void Connection::sendPreparedData(ReadBuffer & input, const String & name)
{
if (!block_out)
{
if (compression == Protocol::Compression::Enable)
maybe_compressed_out = new CompressedWriteBuffer(*out);
else
maybe_compressed_out = out;
block_out = new NativeBlockOutputStream(*maybe_compressed_out);
}
writeVarUInt(Protocol::Client::Data, *out);
if (server_revision >= DBMS_MIN_REVISION_WITH_TEMPORARY_TABLES)
writeStringBinary(name, *out);
copyData(input, *maybe_compressed_out);
maybe_compressed_out->next();
copyData(input, *out);
out->next();
}