mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-13 09:52:38 +00:00
28 lines
696 B
C++
28 lines
696 B
C++
|
#pragma once
|
||
|
|
||
|
#include <Parsers/IAST.h>
|
||
|
#include <Parsers/ASTQueryWithOnCluster.h>
|
||
|
|
||
|
|
||
|
namespace DB
|
||
|
{
|
||
|
|
||
|
class ASTCreateNamedCollectionQuery : public IAST, public ASTQueryWithOnCluster
|
||
|
{
|
||
|
public:
|
||
|
std::string collection_name;
|
||
|
ASTPtr collection_def;
|
||
|
|
||
|
String getID(char) const override { return "CreateNamedCollectionQuery"; }
|
||
|
|
||
|
ASTPtr clone() const override;
|
||
|
|
||
|
void formatImpl(const FormatSettings & s, FormatState & state, FormatStateStacked frame) const override;
|
||
|
|
||
|
ASTPtr getRewrittenASTWithoutOnCluster(const WithoutOnClusterASTRewriteParams &) const override { return removeOnCluster<ASTCreateNamedCollectionQuery>(clone()); }
|
||
|
|
||
|
std::string getCollectionName() const;
|
||
|
};
|
||
|
|
||
|
}
|