Skip to content

Commit 5c5b3ca

Browse files
committed
address comments
1 parent bcc86c0 commit 5c5b3ca

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

sql/core/src/main/scala/org/apache/spark/sql/DataFrameReader.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ class DataFrameReader private[sql](sparkSession: SparkSession) extends Logging {
159159
* @since 1.4.0
160160
*/
161161
def jdbc(url: String, table: String, properties: Properties): DataFrame = {
162-
// connectionProperties should override settings in extraOptions.
162+
// properties should override settings in extraOptions.
163163
this.extraOptions = this.extraOptions ++ properties.asScala
164164
// explicit url and dbtable should override all
165165
this.extraOptions += ("url" -> url, "dbtable" -> table)

sql/core/src/main/scala/org/apache/spark/sql/execution/datasources/jdbc/JDBCRelation.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ private[sql] case class JDBCRelation(
137137
}
138138

139139
override def toString: String = {
140-
val partitioningInfo = if (parts.nonEmpty) s" [numPartitions=${parts.length}]"
140+
val partitioningInfo = if (parts.nonEmpty) s" [numPartitions=${parts.length}]" else ""
141141
// credentials should not be included in the plan output, table information is sufficient.
142142
s"JDBCRelation(${jdbcOptions.table})" + partitioningInfo
143143
}

0 commit comments

Comments
 (0)