You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by gatorsmile <gi...@git.apache.org> on 2017/11/11 19:51:15 UTC
[GitHub] spark pull request #17631: [SPARK-20319][SQL] Already quoted identifiers are...
Github user gatorsmile commented on a diff in the pull request:
https://github.com/apache/spark/pull/17631#discussion_r150391984
--- Diff: sql/core/src/main/scala/org/apache/spark/sql/execution/datasources/jdbc/JdbcUtils.scala ---
@@ -121,7 +121,8 @@ object JdbcUtils extends Logging {
isCaseSensitive: Boolean,
dialect: JdbcDialect): String = {
val columns = if (tableSchema.isEmpty) {
- rddSchema.fields.map(x => dialect.quoteIdentifier(x.name)).mkString(",")
+ rddSchema.fields.map(
+ x => dialect.quoteIdentifier(x.name.stripPrefix("\"").stripSuffix("\""))).mkString(",")
--- End diff --
Different identifiers are using different quotes. We can do it in the `dialect.quoteIdentifier`.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org