kunal642 commented on a change in pull request #4208: URL: https://github.com/apache/carbondata/pull/4208#discussion_r695604258
########## File path: integration/spark/src/main/spark3.1/org/apache/spark/sql/parser/CarbonSparkSqlParser.scala ########## @@ -130,8 +131,24 @@ class CarbonHelperSqlAstBuilder(conf: SQLConf, val tableProperties = convertPropertiesToLowercase(properties) // validate partition clause - val partitionByStructFields = Option(partitionColumns).toSeq - .flatMap(x => visitPartitionFieldList(x)._2) + var (partitionTransformList, + partitionByStructFields) = visitPartitionFieldList(partitionColumns) + // If the struct fields is empty but partition columns are given, + // then search in table columns to extract the struct fields. + if (partitionByStructFields.isEmpty && !partitionTransformList.isEmpty) { Review comment: change !Seq().empty to Seq().nonEmpty -- 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: dev-unsubscr...@carbondata.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org