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


##########
datafusion/expr/src/logical_plan/plan.rs:
##########
@@ -1487,7 +1488,7 @@ pub struct CreateExternalTable {
     /// SQL used to create the table, if available
     pub definition: Option<String>,
     /// File compression type (GZIP, BZIP2, XZ)
-    pub file_compression_type: String,
+    pub file_compression_type: CompressionTypeVariant,

Review Comment:
   👍 



##########
datafusion/sql/src/parser.rs:
##########
@@ -724,4 +726,13 @@ mod tests {
 
         Ok(())
     }
+
+    #[test]
+    fn invalid_compression_type() {
+        let sql = "CREATE EXTERNAL TABLE t STORED AS CSV COMPRESSION TYPE ZZZ 
LOCATION 'blahblah'";
+        expect_parse_error(
+            sql,
+            "sql parser error: Unsupported file compression type ZZZ",

Review Comment:
   👍 



-- 
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