zml1206 commented on code in PR #10525:
URL:
https://github.com/apache/incubator-gluten/pull/10525#discussion_r2299677061
##########
gluten-substrait/src/main/scala/org/apache/spark/sql/hive/HiveTableScanExecTransformer.scala:
##########
@@ -63,12 +63,12 @@ case class HiveTableScanExecTransformer(
override def getMetadataColumns(): Seq[AttributeReference] = Seq.empty
- override def outputAttributes(): Seq[Attribute] = {
- if (prunedOutput.nonEmpty) {
- prunedOutput
- } else {
- output
- }
+ override val output: Seq[Attribute] = if (prunedOutput.nonEmpty) {
+ prunedOutput
+ } else {
+ // Retrieve the original attributes based on expression ID so that
capitalization matches.
+ val originalAttributes = AttributeMap(relation.output.map(a => a -> a))
+ requestedAttributes.map(attr => originalAttributes.getOrElse(attr,
attr)).distinct
Review Comment:
Why not use super.output?
--
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]