Skip to content

Commit

Permalink
fix broken CI
Browse files Browse the repository at this point in the history
  • Loading branch information
jiacai2050 committed Feb 2, 2023
1 parent 05c3cb2 commit 6e12b65
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
5 changes: 3 additions & 2 deletions datafusion/common/src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -181,10 +181,10 @@ config_namespace! {
config_namespace! {
/// Options related to SQL parser
pub struct SqlParserOptions {
/// Whether to parse float as decimal
/// When set to true, sql parser will parse float as decimal type
pub parse_float_as_decimal: bool, default = false

/// Whether to normalize ident
/// When set to true, sql parser will normalize ident(convert ident to lowercase when not quoted)
pub enable_ident_normalization: bool, default = true

}
Expand Down Expand Up @@ -375,6 +375,7 @@ impl ConfigField for ConfigOptions {
self.execution.visit(v, "datafusion.execution", "");
self.optimizer.visit(v, "datafusion.optimizer", "");
self.explain.visit(v, "datafusion.explain", "");
self.sql_parser.visit(v, "datafusion.sql_parser", "");
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,8 @@ datafusion.optimizer.repartition_joins true
datafusion.optimizer.repartition_windows true
datafusion.optimizer.skip_failed_rules true
datafusion.optimizer.top_down_join_key_reordering true
datafusion.sql_parser.enable_ident_normalization true
datafusion.sql_parser.parse_float_as_decimal false

# show_variable_in_config_options
query R
Expand Down Expand Up @@ -366,4 +368,4 @@ WITH HEADER ROW LOCATION '../../testing/data/csv/aggregate_test_100.csv';
query CCCC
SHOW CREATE TABLE abc;
----
datafusion public abc CREATE EXTERNAL TABLE abc STORED AS CSV LOCATION ../../testing/data/csv/aggregate_test_100.csv
datafusion public abc CREATE EXTERNAL TABLE abc STORED AS CSV LOCATION ../../testing/data/csv/aggregate_test_100.csv
4 changes: 2 additions & 2 deletions docs/source/user-guide/configs.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,5 +69,5 @@ Environment variables are read during `SessionConfig` initialisation so they mus
| datafusion.optimizer.hash_join_single_partition_threshold | 1048576 | The maximum estimated size in bytes for one input side of a HashJoin will be collected into a single partition |
| datafusion.explain.logical_plan_only | false | When set to true, the explain statement will only print logical plans |
| datafusion.explain.physical_plan_only | false | When set to true, the explain statement will only print physical plans |
| datafusion.sql_parser.parse_float_as_decimal | false | When set to true, the sql_parser will parse float numbers as decimal type |
| datafusion.sql_parser.enable_ident_normalization | true | When set to true, the sql_parser will normalize ident(convert ident to lowercase when not quoted) |
| datafusion.sql_parser.parse_float_as_decimal | false | When set to true, sql parser will parse float as decimal type |
| datafusion.sql_parser.enable_ident_normalization | true | When set to true, sql parser will normalize ident(convert ident to lowercase when not quoted) |

0 comments on commit 6e12b65

Please sign in to comment.