Github user maropu commented on a diff in the pull request:
https://github.com/apache/spark/pull/17758#discussion_r122407108
--- Diff:
sql/hive/src/main/scala/org/apache/spark/sql/hive/HiveMetastoreCatalog.scala ---
@@ -248,6 +249,10 @@ private[hive] class HiveMetastoreCatalog(sparkSession:
SparkSession) extends Log
if (inferenceMode == INFER_AND_SAVE) {
updateCatalogSchema(relation.tableMeta.identifier, schema)
}
+
+ SchemaUtils.checkSchemaColumnNameDuplication(
--- End diff --
I checked in hive-v2.0.1
```
hive> CREATE TABLE t(a INT, b INT, a INT);
FAILED: SemanticException [Error 10036]: Duplicate column name: a
hive> CREATE TABLE t(a INT, b INT, A INT);
FAILED: SemanticException [Error 10036]: Duplicate column name: a
```
Also, I checked in the Hive doc: `Table names and column names are case
insensitive but SerDe and property names are case sensitive.`
https://cwiki.apache.org/confluence/display/Hive/LanguageManual+DDL#LanguageManualDDL-CreateTable
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]