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 2014/07/28 20:56:31 UTC

[7/7] git commit: Add test case for [DRILL-1199] Order by nested inside a where clause fails

Add test case for [DRILL-1199] Order by nested inside a where clause fails


Project: http://git-wip-us.apache.org/repos/asf/incubator-optiq/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-optiq/commit/d861a088
Tree: http://git-wip-us.apache.org/repos/asf/incubator-optiq/tree/d861a088
Diff: http://git-wip-us.apache.org/repos/asf/incubator-optiq/diff/d861a088

Branch: refs/heads/master
Commit: d861a0887f92caf70b045c4a29cc9960589838e5
Parents: b0aff0d
Author: Julian Hyde <jh...@apache.org>
Authored: Mon Jul 28 11:44:57 2014 -0700
Committer: Julian Hyde <jh...@apache.org>
Committed: Mon Jul 28 11:44:57 2014 -0700

----------------------------------------------------------------------
 core/src/test/resources/sql/misc.oq | 11 +++++++++++
 1 file changed, 11 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-optiq/blob/d861a088/core/src/test/resources/sql/misc.oq
----------------------------------------------------------------------
diff --git a/core/src/test/resources/sql/misc.oq b/core/src/test/resources/sql/misc.oq
index 21711f6..aaa7f83 100644
--- a/core/src/test/resources/sql/misc.oq
+++ b/core/src/test/resources/sql/misc.oq
@@ -76,6 +76,17 @@ from "hr"."emps";
 
 !ok
 
+# [DRILL-1199] Order by nested inside a where clause fails
+# (Not that it's right, but Tableau does it.)
+select * from (select * from "hr"."emps" order by "empid") where (0=1);
++-------+--------+------+--------+------------+
+| empid | deptno | name | salary | commission |
++-------+--------+------+--------+------------+
++-------+--------+------+--------+------------+
+(0 rows)
+
+!ok
+
 # [OPTIQ-340] SqlToRelConverter fails with complex join condition
 select e."deptno", d."deptno"
 from "hr"."emps" as e