You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@calcite.apache.org by jh...@apache.org on 2016/02/02 05:34:20 UTC

calcite git commit: Add test case for outer join on one-sided condition

Repository: calcite
Updated Branches:
  refs/heads/master 05a57992a -> 446d1122b


Add test case for outer join on one-sided condition


Project: http://git-wip-us.apache.org/repos/asf/calcite/repo
Commit: http://git-wip-us.apache.org/repos/asf/calcite/commit/446d1122
Tree: http://git-wip-us.apache.org/repos/asf/calcite/tree/446d1122
Diff: http://git-wip-us.apache.org/repos/asf/calcite/diff/446d1122

Branch: refs/heads/master
Commit: 446d1122bda239cc928c8c15cd56edc33c4f30bf
Parents: 05a5799
Author: Julian Hyde <jh...@apache.org>
Authored: Thu Jan 28 09:51:48 2016 -0800
Committer: Julian Hyde <jh...@apache.org>
Committed: Thu Jan 28 09:51:48 2016 -0800

----------------------------------------------------------------------
 core/src/test/resources/sql/outer.iq | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/calcite/blob/446d1122/core/src/test/resources/sql/outer.iq
----------------------------------------------------------------------
diff --git a/core/src/test/resources/sql/outer.iq b/core/src/test/resources/sql/outer.iq
index af8e259..80a32a4 100644
--- a/core/src/test/resources/sql/outer.iq
+++ b/core/src/test/resources/sql/outer.iq
@@ -346,4 +346,20 @@ select * from t1 full join t2 on t1.x = t2.x;
 
 !ok
 
+# Outer join condition that references columns from only one side is
+# effectively pushed down. Checked on Oracle.
+!use scott
+select * from "scott".emp right join "scott".dept on sal < 100;
++-------+-------+-----+-----+----------+-----+------+--------+---------+------------+----------+
+| EMPNO | ENAME | JOB | MGR | HIREDATE | SAL | COMM | DEPTNO | DEPTNO0 | DNAME      | LOC      |
++-------+-------+-----+-----+----------+-----+------+--------+---------+------------+----------+
+|       |       |     |     |          |     |      |        |      10 | ACCOUNTING | NEW YORK |
+|       |       |     |     |          |     |      |        |      20 | RESEARCH   | DALLAS   |
+|       |       |     |     |          |     |      |        |      30 | SALES      | CHICAGO  |
+|       |       |     |     |          |     |      |        |      40 | OPERATIONS | BOSTON   |
++-------+-------+-----+-----+----------+-----+------+--------+---------+------------+----------+
+(4 rows)
+
+!ok
+
 # End outer.iq