```
clickhouse-local \
    --format_regexp_escaping_rule 'Raw' \
    --format_regexp_skip_unmatched 1 \
    --format_regexp '^([^ \.]+)(\.[^ ]+)? +([^ ]+) +(\d+) +(\d+)$' \
    --query "
SELECT replaceRegexpOne(_path, '^.+pageviews-(\\d{4})(\\d{2})(\\d{2})-(\\d{2})(\\d{2})(\\d{2}).gz$', '\1-\2-\3 \4-\5-\6')::DateTime AS time, * 
FROM file('pageviews*.gz', Regexp, 'project String, subproject String, path String, hits UInt64, size UInt64')"
```

```
Code: 117. DB::Exception: No \n after \r at the end of line.: (at row 148660)
: While executing ParallelParsingBlockInputFormat: While executing File. (INCORRECT_DATA)
```

```
clickhouse-local \
    --format_regexp_escaping_rule 'Raw' \
    --format_regexp_skip_unmatched 1 \
    --format_regexp '^([^ \.]+)(\.[^ ]+)? +([^ ]+) +(\d+) +(\d+).*?$' \
    --query "
SELECT replaceRegexpOne(_path, '^.+pageviews-(\\d{4})(\\d{2})(\\d{2})-(\\d{2})(\\d{2})(\\d{2}).gz$', '\1-\2-\3 \4-\5-\6')::DateTime AS time, * 
FROM file('pageviews*.gz', Regexp, 'project String, subproject String, path String, hits UInt64, size UInt64')"
```

```
Code: 117. DB::Exception: No \n after \r at the end of line.: (at row 148660)
: While executing ParallelParsingBlockInputFormat: While executing File. (INCORRECT_DATA)
```
void resetParser() override;
    void setReadBuffer(ReadBuffer & in_) override;
private:
    RegexpRowInputFormat(std::unique_ptr<PeekableReadBuffer> buf_, const Block & header_, Params params_, const FormatSettings & format_settings_);
    using EscapingRule = FormatSettings::EscapingRule;
    bool readRow(MutableColumns & columns, RowReadExtension & ext) override;
    bool readField(size_t index, MutableColumns & columns);
    void readFieldsFromMatch(MutableColumns & columns, RowReadExtension & ext);
    std::unique_ptr<PeekableReadBuffer> buf;
    const FormatSettings format_settings;
    const EscapingRule escaping_rule;
    RegexpFieldExtractor field_extractor;
};
class RegexpSchemaReader : public IRowSchemaReader
{
public:
    RegexpSchemaReader(ReadBuffer & in_, const FormatSettings & format_settings, ContextPtr context_);
private:
    DataTypes readRowAndGetDataTypes() override;
    using EscapingRule = FormatSettings::EscapingRule;
    const FormatSettings format_settings;
    RegexpFieldExtractor field_extractor;
    PeekableReadBuffer buf;
    ContextPtr context;
};
}