ClickHouse/src/Parsers/ParserDropQuery.h

27 lines
508 B
C++
Raw Normal View History

2011-11-05 23:31:19 +00:00
#pragma once
#include <Parsers/IParserBase.h>
#include <Parsers/ExpressionElementParsers.h>
2011-11-05 23:31:19 +00:00
namespace DB
{
2017-05-27 17:29:55 +00:00
/** Query like this:
2020-11-30 17:52:32 +00:00
* DROP|DETACH|TRUNCATE TABLE [IF EXISTS] [db.]name [PERMANENTLY]
2011-11-05 23:31:19 +00:00
*
2017-05-27 17:29:55 +00:00
* Or:
2011-11-05 23:31:19 +00:00
* DROP DATABASE [IF EXISTS] db
2019-10-08 11:10:29 +00:00
*
* Or:
* DROP DICTIONARY [IF EXISTS] [db.]name
2011-11-05 23:31:19 +00:00
*/
class ParserDropQuery : public IParserBase
{
protected:
const char * getName() const override{ return "DROP query"; }
bool parseImpl(Pos & pos, ASTPtr & node, Expected & expected) override;
2011-11-05 23:31:19 +00:00
};
}