LiShuMing commented on a change in pull request #25192: [SPARK-28436][SQL] 
Throw better exception when datasource's schema i…
URL: https://github.com/apache/spark/pull/25192#discussion_r308070187
 
 

 ##########
 File path: 
sql/core/src/main/scala/org/apache/spark/sql/execution/datasources/DataSource.scala
 ##########
 @@ -339,7 +339,9 @@ case class DataSource(
         val baseRelation =
           dataSource.createRelation(sparkSession.sqlContext, 
caseInsensitiveOptions)
         if (baseRelation.schema != schema) {
-          throw new AnalysisException(s"$className does not allow 
user-specified schemas.")
+          throw new AnalysisException(s"$className does not allow 
user-specified schemas, " +
+              s"user-specified schemas are not same as source schema: \n" +
 
 Review comment:
   OK, Thanks for @HyukjinKwon 's replies.

----------------------------------------------------------------
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


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to