This is an automated email from the ASF dual-hosted git repository.

changchen pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-gluten.git


The following commit(s) were added to refs/heads/main by this push:
     new 184476148 [GLUTEN-6981][CH]Not supported operator 
TakeOrderedAndProjectExecTransformer for BroadcastRelation (#6982)
184476148 is described below

commit 184476148e3a587e3212394ca67cea05c3202af4
Author: loudongfeng <[email protected]>
AuthorDate: Fri Aug 23 23:22:29 2024 +0800

    [GLUTEN-6981][CH]Not supported operator 
TakeOrderedAndProjectExecTransformer for BroadcastRelation (#6982)
---
 .../backendsapi/clickhouse/CHSparkPlanExecApi.scala     |  2 ++
 .../tpcds/GlutenClickHouseTPCDSParquetSuite.scala       | 17 +++++++++++++++++
 2 files changed, 19 insertions(+)

diff --git 
a/backends-clickhouse/src/main/scala/org/apache/gluten/backendsapi/clickhouse/CHSparkPlanExecApi.scala
 
b/backends-clickhouse/src/main/scala/org/apache/gluten/backendsapi/clickhouse/CHSparkPlanExecApi.scala
index 676126965..bfa59aee7 100644
--- 
a/backends-clickhouse/src/main/scala/org/apache/gluten/backendsapi/clickhouse/CHSparkPlanExecApi.scala
+++ 
b/backends-clickhouse/src/main/scala/org/apache/gluten/backendsapi/clickhouse/CHSparkPlanExecApi.scala
@@ -524,6 +524,8 @@ class CHSparkPlanExecApi extends SparkPlanExecApi with 
Logging {
             wrapChild(r2c)
           case union: ColumnarUnionExec =>
             wrapChild(union)
+          case ordered: TakeOrderedAndProjectExecTransformer =>
+            wrapChild(ordered)
           case other =>
             throw new GlutenNotSupportException(
               s"Not supported operator ${other.nodeName} for 
BroadcastRelation")
diff --git 
a/backends-clickhouse/src/test/scala/org/apache/gluten/execution/tpcds/GlutenClickHouseTPCDSParquetSuite.scala
 
b/backends-clickhouse/src/test/scala/org/apache/gluten/execution/tpcds/GlutenClickHouseTPCDSParquetSuite.scala
index d0b270d2a..08f4522d9 100644
--- 
a/backends-clickhouse/src/test/scala/org/apache/gluten/execution/tpcds/GlutenClickHouseTPCDSParquetSuite.scala
+++ 
b/backends-clickhouse/src/test/scala/org/apache/gluten/execution/tpcds/GlutenClickHouseTPCDSParquetSuite.scala
@@ -336,5 +336,22 @@ class GlutenClickHouseTPCDSParquetSuite extends 
GlutenClickHouseTPCDSAbstractSui
     compareResultsAgainstVanillaSpark(sql5, compareResult = true, _ => {})
   }
 
+  test("TakeOrderedAndProjectExecTransformer in broadcastRelation") {
+    val q =
+      """
+        | with dd as (
+        | select d_date_sk, count(*) as cn
+        | from date_dim
+        | where d_date_sk is not null
+        | group by d_date_sk
+        | order by cn desc
+        | limit 10)
+        | select count(ss.ss_sold_date_sk)
+        | from store_sales ss, dd
+        | where ss_sold_date_sk=dd.d_date_sk+1
+        |""".stripMargin
+    
runQueryAndCompare(q)(checkGlutenOperatorMatch[TakeOrderedAndProjectExecTransformer])
+  }
+
 }
 // scalastyle:on line.size.limit


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

Reply via email to