ankitsultana commented on code in PR #18158:
URL: https://github.com/apache/pinot/pull/18158#discussion_r3069078358


##########
pinot-query-planner/src/test/resources/queries/PhysicalOptimizerPlans.json:
##########
@@ -1126,5 +1023,109 @@
         ]
       }
     ]
+  },
+  "physical_opt_lookup_join": {
+    "queries": [
+      {
+        "description": "Simple lookup join — dim table uses 
LOOKUP_LOCAL_EXCHANGE, join is isolated by IDENTITY_EXCHANGE above and on the 
left",
+        "sql": "SET usePhysicalOptimizer=true; EXPLAIN PLAN FOR SELECT /*+ 
joinOptions(join_strategy='lookup') */ a.col1, b.col2 FROM a JOIN b ON a.col1 = 
b.col1",
+        "output": [
+          "Execution Plan",
+          "\nPhysicalExchange(exchangeStrategy=[SINGLETON_EXCHANGE])",
+          "\n  PhysicalProject(col1=[$0], col2=[$2])",
+          "\n    PhysicalExchange(exchangeStrategy=[IDENTITY_EXCHANGE])",
+          "\n      PhysicalJoin(condition=[=($0, $1)], joinType=[inner])",
+          "\n        PhysicalExchange(exchangeStrategy=[IDENTITY_EXCHANGE])",
+          "\n          PhysicalProject(col1=[$0])",
+          "\n            PhysicalTableScan(table=[[default, a]])",
+          "\n        
PhysicalExchange(exchangeStrategy=[LOOKUP_LOCAL_EXCHANGE])",
+          "\n          PhysicalProject(col1=[$0], col2=[$1])",
+          "\n            PhysicalTableScan(table=[[default, b]])",
+          "\n"
+        ]
+      },
+      {
+        "description": "Lookup join with aggregation — lookup join feeds into 
GROUP BY with leaf/final aggregate split",

Review Comment:
   is it possible to add a model query that you folks are using in your 
production? want to make sure that regressions can be caught by unit tests 
itself



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