quickstep-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jianq...@apache.org
Subject [8/8] incubator-quickstep git commit: updates
Date Thu, 07 Jul 2016 18:57:58 GMT
updates


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

Branch: refs/heads/adaptive-bloom-filters
Commit: 8904ba1214553fdc73000b9061d931a93f417af4
Parents: a3ba59f
Author: Jianqiao Zhu <jianqiao@cs.wisc.edu>
Authored: Thu Jul 7 13:57:21 2016 -0500
Committer: Jianqiao Zhu <jianqiao@cs.wisc.edu>
Committed: Thu Jul 7 13:57:21 2016 -0500

----------------------------------------------------------------------
 query_optimizer/physical/Physical.hpp | 5 +++++
 utility/PlanVisualizer.cpp            | 4 +++-
 2 files changed, 8 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-quickstep/blob/8904ba12/query_optimizer/physical/Physical.hpp
----------------------------------------------------------------------
diff --git a/query_optimizer/physical/Physical.hpp b/query_optimizer/physical/Physical.hpp
index 721b987..4603efc 100644
--- a/query_optimizer/physical/Physical.hpp
+++ b/query_optimizer/physical/Physical.hpp
@@ -89,6 +89,11 @@ class Physical : public OptimizerTree<Physical> {
     return false;
   }
 
+  virtual double estimateSelectivity(
+      const expressions::AttributeReferencePtr &attribute) const {
+    return 1.0;
+  }
+
  protected:
   /**
    * @brief Constructor.

http://git-wip-us.apache.org/repos/asf/incubator-quickstep/blob/8904ba12/utility/PlanVisualizer.cpp
----------------------------------------------------------------------
diff --git a/utility/PlanVisualizer.cpp b/utility/PlanVisualizer.cpp
index 37fa790..26c555e 100644
--- a/utility/PlanVisualizer.cpp
+++ b/utility/PlanVisualizer.cpp
@@ -118,7 +118,9 @@ void PlanVisualizer::visit(const P::PhysicalPtr &input) {
 
     for (const auto &attr : child->getOutputAttributes()) {
       if (referenced_ids.find(attr->id()) != referenced_ids.end()) {
-        edge_info.labels.emplace_back(attr->attribute_alias());
+        std::ostringstream oss;
+        oss << attr->attribute_alias() << " : " << child->estimateSelectivity(attr);
+        edge_info.labels.emplace_back(oss.str());
       }
     }
   }


Mime
View raw message