mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-21 15:12:02 +00:00
fix defaults with list expressions
This commit is contained in:
parent
2876aadba7
commit
a7fcae2759
@ -6,7 +6,7 @@
|
||||
#include <Storages/TableMetadata.h>
|
||||
#include <Parsers/formatAST.h>
|
||||
#include <Parsers/parseQuery.h>
|
||||
#include <Parsers/ExpressionElementParsers.h>
|
||||
#include <Parsers/ExpressionListParsers.h>
|
||||
#include <Core/ColumnWithTypeAndName.h>
|
||||
#include <Columns/IColumn.h>
|
||||
#include <Core/Block.h>
|
||||
@ -116,7 +116,7 @@ namespace DB
|
||||
size_t data_size = proto_column.column->byteSize();
|
||||
Proto::Context::Reader proto_context = deserializeProto<Proto::Context>(plain_data.data, data_size);
|
||||
|
||||
ParserExpressionElement parser;
|
||||
ParserTernaryOperatorExpression parser;
|
||||
|
||||
for (auto proto_database : proto_context.getDatabases())
|
||||
{
|
||||
|
@ -6,7 +6,10 @@ CREATE TABLE IF NOT EXISTS test.defaults
|
||||
y UInt32,
|
||||
a UInt32 DEFAULT x + y,
|
||||
b Float32 DEFAULT log(1 + x + y),
|
||||
c UInt32 DEFAULT 42
|
||||
c UInt32 DEFAULT 42,
|
||||
d DEFAULT x + y,
|
||||
e MATERIALIZED x + y,
|
||||
f ALIAS x + y
|
||||
) ENGINE = Memory;
|
||||
|
||||
INSERT INTO test.defaults FORMAT JSONEachRow {"x":1, "y":1};
|
||||
|
Loading…
Reference in New Issue
Block a user