maropu commented on a change in pull request #32858: URL: https://github.com/apache/spark/pull/32858#discussion_r649659422
########## File path: sql/catalyst/src/main/antlr4/org/apache/spark/sql/catalyst/parser/SqlBase.g4 ########## @@ -930,7 +930,7 @@ complexColTypeList ; complexColType - : identifier ':' dataType (NOT NULL)? commentSpec? + : identifier ':'? dataType (NOT NULL)? commentSpec? Review comment: Could you update the SQL doc? https://github.com/apache/spark/blame/master/docs/sql-ref-datatypes.md#L197 ########## File path: docs/sql-ref-datatypes.md ########## @@ -194,7 +194,7 @@ The following table shows the type names as well as aliases used in Spark SQL pa |**DecimalType**|DECIMAL, DEC, NUMERIC| |**CalendarIntervalType**|INTERVAL| |**ArrayType**|ARRAY\<element_type>| -|**StructType**|STRUCT<field1_name: field1_type, field2_name: field2_type, ...>| +|**StructType**|STRUCT<field1_name field1_type, field2_name field2_type, ...>| Review comment: Instead of removing `:`, how about writing `Note that : is optional` like https://github.com/apache/spark/blame/master/docs/sql-ref-datatypes.md#L172 ? -- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org