beliefer commented on code in PR #7691:
URL: https://github.com/apache/incubator-gluten/pull/7691#discussion_r1818462280
##########
backends-clickhouse/src/main/scala/org/apache/gluten/extension/RewriteDateTimestampComparisonRule.scala:
##########
@@ -37,7 +37,7 @@ import org.apache.spark.unsafe.types.UTF8String
// This rule try to make the filter condition into integer comparison, which
is more efficient.
// The above example will be rewritten into
// select * from table where to_unixtime('2023-11-02', 'yyyy-MM-dd') >=
unix_timestamp
-class RewriteDateTimestampComparisonRule(session: SparkSession, conf: SQLConf)
Review Comment:
If there is an active `SparkSession`, the proper `SQLConf` associated with
the thread's active session is used. So we should use `spark.sessionState.conf`
first.
`Glutenconfig.getConf` actually proxies `SQLConf.get`, which will prioritize
obtaining SQLConf from the active session, otherwise the default SQLConf will
be used.
--
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]