mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-18 20:32:43 +00:00
32 lines
541 B
C++
32 lines
541 B
C++
#pragma once
|
|
|
|
#include <Interpreters/Context.h>
|
|
#include <Interpreters/IInterpreter.h>
|
|
#include <Parsers/IAST_fwd.h>
|
|
|
|
|
|
namespace DB
|
|
{
|
|
|
|
/// Returns single row with explain results
|
|
class InterpreterExplainQuery : public IInterpreter
|
|
{
|
|
public:
|
|
InterpreterExplainQuery(const ASTPtr & query_, const Context & context_)
|
|
: query(query_), context(context_)
|
|
{}
|
|
|
|
BlockIO execute() override;
|
|
|
|
static Block getSampleBlock();
|
|
|
|
private:
|
|
ASTPtr query;
|
|
const Context & context;
|
|
|
|
BlockInputStreamPtr executeImpl();
|
|
};
|
|
|
|
|
|
}
|