Skip to content

Commit 49339ac

Browse files
committed
Add DOUBLE as data type name alias for FLOAT64
This fixes parsing of SimpleAggregateFunction(sum, Double) where Double should be recognized as a data type, not an identifier. Fixed 6 tests: - 00915_simple_aggregate_function/stmt3 - 00915_simple_aggregate_function_summing_merge_tree/stmt3 - 01392_column_resolve/stmt1, stmt2 - 02775_show_columns_called_from_clickhouse/stmt4 - 02790_fix_coredump_when_compile_expression/stmt1
1 parent 8814f03 commit 49339ac

6 files changed

Lines changed: 6 additions & 27 deletions

File tree

parser/parser.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4503,7 +4503,7 @@ func (p *Parser) isDataTypeName(name string) bool {
45034503
types := []string{
45044504
"INT", "INT8", "INT16", "INT32", "INT64", "INT128", "INT256",
45054505
"UINT8", "UINT16", "UINT32", "UINT64", "UINT128", "UINT256",
4506-
"FLOAT32", "FLOAT64", "FLOAT", "BFLOAT16",
4506+
"FLOAT32", "FLOAT64", "FLOAT", "DOUBLE", "BFLOAT16",
45074507
"DECIMAL", "DECIMAL32", "DECIMAL64", "DECIMAL128", "DECIMAL256", "DEC",
45084508
"STRING", "FIXEDSTRING",
45094509
"UUID", "DATE", "DATE32", "DATETIME", "DATETIME64",
Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1 @@
1-
{
2-
"explain_todo": {
3-
"stmt3": true
4-
}
5-
}
1+
{}
Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1 @@
1-
{
2-
"explain_todo": {
3-
"stmt3": true
4-
}
5-
}
1+
{}
Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1 @@
1-
{
2-
"explain_todo": {
3-
"stmt1": true,
4-
"stmt2": true
5-
}
6-
}
1+
{}
Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1 @@
1-
{
2-
"explain_todo": {
3-
"stmt4": true
4-
}
5-
}
1+
{}
Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1 @@
1-
{
2-
"explain_todo": {
3-
"stmt1": true
4-
}
5-
}
1+
{}

0 commit comments

Comments
 (0)