```
SELECT
    _file,
    _path
FROM file('exists.csv', 'CSVWithNames')

Query id: 8bff0d32-cad0-4832-907a-be39f13ac49c


0 rows in set. Elapsed: 0.099 sec.

Received exception from server (version 22.7.1):
Code: 49. DB::Exception: Received from localhost:9000. DB::Exception: Invalid number of columns in chunk pushed to OutputPort. Expected 2, found 4
Header: _path LowCardinality(String) ColumnLowCardinality(size = 0, UInt8(size = 0), ColumnUnique(size = 1, String(size = 1))), _file LowCardinality(String) ColumnLowCardinality(size = 0, UInt8(size = 0), ColumnUnique(size = 1, String(size = 1)))
Chunk:  ColumnLowCardinality(size = 7385, UInt8(size = 7385), ColumnUnique(size = 1, String(size = 1))) ColumnLowCardinality(size = 7385, UInt8(size = 7385), ColumnUnique(size = 1, String(size = 1))) ColumnLowCardinality(size = 7385, UInt8(size = 7385), ColumnUnique(size = 2, String(size = 2))) ColumnLowCardinality(size = 7385, UInt8(size = 7385), ColumnUnique(size = 2, String(size = 2)))
. (LOGICAL_ERROR)
```

Version 22.7.1.2484

ContextPtr context,
    QueryProcessingStage::Enum ,
    size_t max_block_size,
    unsigned num_streams)
{
    if (use_table_fd)
    {
        paths = {""};   
    }
    else
    {
        if (paths.size() == 1 && !fs::exists(paths[0]))
        {
            if (context->getSettingsRef().engine_file_empty_if_not_exists)
                return Pipe(std::make_shared<NullSource>(storage_snapshot->getSampleBlockForColumns(column_names)));
            else
                throw Exception("File " + paths[0] + " doesn't exist", ErrorCodes::FILE_DOESNT_EXIST);
        }
    }
    auto files_info = std::make_shared<StorageFileSource::FilesInfo>();
    files_info->files = paths;
    files_info->total_bytes_to_read = total_bytes_to_read;
    for (const auto & column : column_names)
    {
        if (column == "_path")
            files_info->need_path_column = true;
        if (column == "_file")
            files_info->need_file_column = true;
    }
    auto this_ptr = std::static_pointer_cast<StorageFile>(shared_from_this());