#pragma once #include #include #include #include #include namespace DB { class Pipe; /// Prepares a input format, which produce data containing in INSERT query. InputFormatPtr getInputFormatFromASTInsertQuery( const ASTPtr & ast, bool with_buffers, const Block & header, ContextPtr context, const ASTPtr & input_function); /// Prepares a pipe from input format got from ASTInsertQuery, /// which produce data containing in INSERT query. Pipe getSourceFromInputFormat( const ASTPtr & ast, InputFormatPtr format, ContextPtr context, const ASTPtr & input_function); /// Prepares a pipe which produce data containing in INSERT query. Pipe getSourceFromASTInsertQuery( const ASTPtr & ast, bool with_buffers, const Block & header, ContextPtr context, const ASTPtr & input_function); class ReadBuffer; /// Prepares a read buffer, that allows to read inlined data /// from ASTInsertQuert directly, and from tail buffer, if it exists. std::unique_ptr getReadBufferFromASTInsertQuery(const ASTPtr & ast); }