ClickHouse/src/Interpreters/InterpreterExplainQuery.h

28 lines
479 B
C++
Raw Normal View History

2018-09-21 15:20:23 +00:00
#pragma once
#include <Interpreters/IInterpreter.h>
2019-03-11 14:01:45 +00:00
#include <Parsers/IAST_fwd.h>
2018-09-21 15:20:23 +00:00
namespace DB
{
/// Returns single row with explain results
class InterpreterExplainQuery : public IInterpreter, WithContext
2018-09-21 15:20:23 +00:00
{
public:
InterpreterExplainQuery(const ASTPtr & query_, ContextPtr context_) : WithContext(context_), query(query_) { }
2018-09-21 15:20:23 +00:00
BlockIO execute() override;
static Block getSampleBlock();
private:
ASTPtr query;
BlockInputStreamPtr executeImpl();
};
}