I have an ORC file with 10 mln rows. I created a table with the same structure and executed `insert into <table> select * from file('<filename>', ORC, '<fields>')` . Rows were inserted, and `select count(1) from <table>` gave me 10 mln. But query didn't stop, and still is running. `select query, written_rows from system.processes` shows 700 mln inserted rows and counting.

`CREATE TABLE t (a lot of ordinary fields) ENGINE = ReplicatedReplacingMergeTree('/clickhouse/tables/{shard}/t', '{replica}') PARTITION BY toYYYYMM(calday) ORDER BY (calday) SETTINGS index_granularity = 8192`
clickhouse version 20.8.2.3.

**Expected behavior**
Query is finished.
#include "ORCBlockInputFormat.h"
#if USE_ORC
#include <Formats/FormatFactory.h>
#include <IO/ReadBufferFromMemory.h>
#include <IO/WriteHelpers.h>
#include <IO/copyData.h>
#include <arrow/adapters/orc/adapter.h>
#include <arrow/io/memory.h>
#include "ArrowBufferedStreams.h"
#include "ArrowColumnToCHColumn.h"
namespace DB
{
namespace ErrorCodes
{
    extern const int BAD_ARGUMENTS;
    extern const int CANNOT_READ_ALL_DATA;
}
ORCBlockInputFormat::ORCBlockInputFormat(ReadBuffer & in_, Block header_) : IInputFormat(std::move(header_), in_)