mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-25 17:12:03 +00:00
to MaterializeMySQL_support_drop_mulit_table-fix code-style
This commit is contained in:
parent
6a998917b0
commit
47385d259c
@ -549,7 +549,7 @@ ASTs InterpreterDropImpl::getRewrittenQueries(
|
||||
return {};
|
||||
TQuery::QualifiedNames tables = drop_query.names;
|
||||
ASTs rewritten_querys;
|
||||
for(const auto & table: tables)
|
||||
for (const auto & table: tables)
|
||||
{
|
||||
const auto & database_name = resolveDatabase(table.schema, mysql_database, mapped_to_database, context);
|
||||
if (database_name != mapped_to_database)
|
||||
@ -562,7 +562,7 @@ ASTs InterpreterDropImpl::getRewrittenQueries(
|
||||
rewritten_query->is_view = false;
|
||||
rewritten_query->if_exists = drop_query.if_exists;
|
||||
rewritten_querys.push_back(rewritten_query);
|
||||
}
|
||||
}
|
||||
return rewritten_querys;
|
||||
}
|
||||
|
||||
|
@ -55,7 +55,7 @@ bool ParserDropQuery::parseImpl(IParser::Pos & pos, ASTPtr & node, Expected & ex
|
||||
bool is_temporary = false;
|
||||
|
||||
if (s_truncate.ignore(pos, expected) && s_table.ignore(pos, expected))
|
||||
{
|
||||
{
|
||||
is_drop = false;
|
||||
query->kind = ASTDropQuery::Kind::Table;
|
||||
ASTDropQuery::QualifiedName name;
|
||||
@ -63,7 +63,7 @@ bool ParserDropQuery::parseImpl(IParser::Pos & pos, ASTPtr & node, Expected & ex
|
||||
names.push_back(name);
|
||||
else
|
||||
return false;
|
||||
}
|
||||
}
|
||||
else if (s_drop.ignore(pos, expected))
|
||||
{
|
||||
if (s_database.ignore(pos, expected))
|
||||
@ -92,7 +92,7 @@ bool ParserDropQuery::parseImpl(IParser::Pos & pos, ASTPtr & node, Expected & ex
|
||||
if (!(name_p.parse(pos, index, expected) && on.ignore(pos, expected)))
|
||||
return false;
|
||||
}
|
||||
else if (s_event.ignore(pos, expected) || s_function.ignore(pos, expected) || s_server.ignore(pos, expected)
|
||||
else if (s_event.ignore(pos, expected) || s_function.ignore(pos, expected) || s_server.ignore(pos, expected)
|
||||
|| s_trigger.ignore(pos, expected))
|
||||
{
|
||||
query->kind = ASTDropQuery::Kind::Other;
|
||||
@ -117,8 +117,8 @@ bool ParserDropQuery::parseImpl(IParser::Pos & pos, ASTPtr & node, Expected & ex
|
||||
if (!ParserList::parseUtil(pos, expected, parse_element, false))
|
||||
return false;
|
||||
}
|
||||
}
|
||||
else
|
||||
}
|
||||
else
|
||||
return false;
|
||||
|
||||
query->if_exists = if_exists;
|
||||
@ -128,8 +128,7 @@ bool ParserDropQuery::parseImpl(IParser::Pos & pos, ASTPtr & node, Expected & ex
|
||||
query->is_drop = is_drop;
|
||||
query->is_temporary = is_temporary;
|
||||
|
||||
return true;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -27,7 +27,6 @@ public:
|
||||
Index,
|
||||
/// TRIGGER,FUNCTION,EVENT and so on, No need for support
|
||||
Other,
|
||||
|
||||
};
|
||||
Kind kind;
|
||||
struct QualifiedName
|
||||
|
Loading…
Reference in New Issue
Block a user