szehon-ho commented on code in PR #57722:
URL: https://github.com/apache/spark/pull/57722#discussion_r3716068831


##########
sql/pipelines/src/main/scala/org/apache/spark/sql/pipelines/graph/DataflowGraph.scala:
##########
@@ -170,14 +171,21 @@ case class DataflowGraph(
   /**
    * A map of the inferred schema of each table, computed by merging the 
analyzed schemas
    * of all flows writing to that table.
+   *
+   * The merge honors the session's `spark.sql.caseSensitive`: under 
case-insensitive analysis two
+   * flows emitting column names that differ only in case contribute a single 
column rather than
+   * both, which would otherwise produce a target schema the engine's own 
resolver cannot
+   * disambiguate. Which of the two spellings survives follows the order the 
flows are merged in,
+   * which this map does not define, so callers should not depend on a 
particular casing.
    */
   lazy val inferredSchema: Map[TableIdentifier, StructType] = {
+    val caseSensitive = 
SparkSession.active.sessionState.conf.caseSensitiveAnalysis

Review Comment:
   SQLConf.get.caseSensitiveAnalysis?
   
   (for subsequent ones too)
   



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to