mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-23 08:02:02 +00:00
Add SELECT @@Version fake value '5.7.30' #11089
This commit is contained in:
parent
6f28d7b8b5
commit
2aa92a8563
@ -77,7 +77,8 @@ private:
|
||||
DataTypePtr type;
|
||||
Field value;
|
||||
};
|
||||
std::unordered_map<String, TypeAndValue> global_variable_map = {{"max_allowed_packet", {std::make_shared<DataTypeInt32>(), 67108864}}};
|
||||
std::unordered_map<String, TypeAndValue> global_variable_map = {
|
||||
{"max_allowed_packet", {std::make_shared<DataTypeInt32>(), 67108864}}, {"version", {std::make_shared<DataTypeString>(), "5.7.30"}}};
|
||||
};
|
||||
|
||||
|
||||
|
@ -1295,7 +1295,7 @@ bool ParserMySQLGlobalVariable::parseImpl(Pos & pos, ASTPtr & node, Expected & e
|
||||
function_node->children.push_back(expr_list_args);
|
||||
|
||||
node = function_node;
|
||||
node->setAlias(name);
|
||||
node->setAlias("@@" + name);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -1,13 +1,15 @@
|
||||
0
|
||||
"max_allowed_packet"
|
||||
"@@max_allowed_packet"
|
||||
67108864
|
||||
"MAX_ALLOWED_PACKET"
|
||||
"@@MAX_ALLOWED_PACKET"
|
||||
67108864
|
||||
"max_allowed_packet","number"
|
||||
"@@max_allowed_packet","number"
|
||||
67108864,0
|
||||
67108864,1
|
||||
67108864,2
|
||||
"auto_increment_increment"
|
||||
"@@auto_increment_increment"
|
||||
0
|
||||
"auto_increment_increment"
|
||||
0
|
||||
"@@Version"
|
||||
"5.7.30"
|
||||
|
@ -4,3 +4,4 @@ SELECT @@MAX_ALLOWED_PACKET FORMAT CSVWithNames;
|
||||
SELECT @@max_allowed_packet, number FROM system.numbers LIMIT 3 FORMAT CSVWithNames;
|
||||
SELECT @@session.auto_increment_increment FORMAT CSVWithNames;
|
||||
SELECT @@session.auto_increment_increment AS auto_increment_increment FORMAT CSVWithNames;
|
||||
SELECT @@Version FORMAT CSVWithNames;
|
||||
|
Loading…
Reference in New Issue
Block a user