alamb commented on code in PR #3309:
URL: https://github.com/apache/arrow-datafusion/pull/3309#discussion_r959915916


##########
datafusion/core/tests/sql/mod.rs:
##########
@@ -628,7 +628,7 @@ async fn register_aggregate_csv_by_sql(ctx: 
&SessionContext) {
             "
     CREATE EXTERNAL TABLE aggregate_test_100 (
         c1  VARCHAR NOT NULL,
-        c2  INT NOT NULL,
+        c2  TINYINT NOT NULL,

Review Comment:
   for anyone else wondering, `c8` is still a `INT` column



##########
datafusion/sql/src/planner.rs:
##########
@@ -2705,11 +2656,31 @@ pub fn convert_simple_data_type(sql_type: &SQLDataType) 
-> Result<DataType> {
         SQLDataType::Date => Ok(DataType::Date32),
         SQLDataType::Time => Ok(DataType::Time64(TimeUnit::Nanosecond)),
         SQLDataType::Decimal(precision, scale) => 
make_decimal_type(*precision, *scale),
-        SQLDataType::Binary(_) => Ok(DataType::Binary),
         SQLDataType::Bytea => Ok(DataType::Binary),
-        other => Err(DataFusionError::NotImplemented(format!(
+        // Explicitly list all other types so that if sqlparser

Review Comment:
   this is a nice refactor to remove duplication



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to