quickstep-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From zu...@apache.org
Subject [05/46] incubator-quickstep git commit: Adds support for scalar subqueries (#185)
Date Mon, 16 May 2016 20:55:42 GMT
Adds support for scalar subqueries (#185)

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

Branch: refs/heads/master
Commit: bf4e011b5b3c66364a7ff7929968199e05ec1182
Parents: 2381dde
Author: Jianqiao Zhu <jianqiao@cs.wisc.edu>
Authored: Thu Apr 21 16:08:39 2016 -0500
Committer: Jignesh Patel <pateljm@users.noreply.github.com>
Committed: Thu Apr 21 16:08:39 2016 -0500

----------------------------------------------------------------------
 parser/ParseSubqueryExpression.cpp              |    5 +-
 parser/SqlParser.ypp                            |    3 +
 parser/preprocessed/SqlParser_gen.cpp           | 1675 +++++++++---------
 parser/tests/Select.test                        |   36 +-
 parser/tests/TPCH.test                          |  463 ++++-
 .../expressions/SubqueryExpression.cpp          |   11 +-
 query_optimizer/resolver/Resolver.cpp           |    8 +-
 query_optimizer/rules/CMakeLists.txt            |    1 +
 query_optimizer/rules/UnnestSubqueries.cpp      |   49 +-
 .../tests/execution_generator/Select.test       |   55 +-
 .../tests/logical_generator/Select.test         |  370 ++++
 .../tests/physical_generator/Select.test        |  614 +++++++
 query_optimizer/tests/resolver/Select.test      |  144 ++
 13 files changed, 2563 insertions(+), 871 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-quickstep/blob/bf4e011b/parser/ParseSubqueryExpression.cpp
----------------------------------------------------------------------
diff --git a/parser/ParseSubqueryExpression.cpp b/parser/ParseSubqueryExpression.cpp
index 1673a74..556b19d 100644
--- a/parser/ParseSubqueryExpression.cpp
+++ b/parser/ParseSubqueryExpression.cpp
@@ -1,6 +1,8 @@
 /**
  *   Copyright 2011-2015 Quickstep Technologies LLC.
  *   Copyright 2015 Pivotal Software, Inc.
+ *   Copyright 2016, Quickstep Research Group, Computer Sciences Department,
+ *     University of Wisconsin—Madison.
  *
  *   Licensed under the Apache License, Version 2.0 (the "License");
  *   you may not use this file except in compliance with the License.
@@ -27,7 +29,8 @@ namespace quickstep {
 class ParseTreeNode;
 
 std::string ParseSubqueryExpression::generateName() const {
-  LOG(FATAL) << "ParseSubqueryExpression::generateName() is not implemented yet";
+  // TODO(jianqiao): generate a more informative name for ParseSubqueryExpression.
+  return getName();
 }
 
 void ParseSubqueryExpression::getFieldStringItems(

http://git-wip-us.apache.org/repos/asf/incubator-quickstep/blob/bf4e011b/parser/SqlParser.ypp
----------------------------------------------------------------------
diff --git a/parser/SqlParser.ypp b/parser/SqlParser.ypp
index bb19d8b..a8ec821 100644
--- a/parser/SqlParser.ypp
+++ b/parser/SqlParser.ypp
@@ -1503,6 +1503,9 @@ expression_base:
   }
   | '(' add_expression ')' {
     $$ = $2;
+  }
+  | subquery_expression {
+    $$ = $1;
   };
 
 function_call:


Mime
View raw message