You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@calcite.apache.org by "HULING (JIRA)" <ji...@apache.org> on 2017/11/09 03:57:00 UTC
[jira] [Created] (CALCITE-2047) java.lang.AssertionError: Type
mismatch
HULING created CALCITE-2047:
-------------------------------
Summary: java.lang.AssertionError: Type mismatch
Key: CALCITE-2047
URL: https://issues.apache.org/jira/browse/CALCITE-2047
Project: Calcite
Issue Type: Bug
Components: core
Affects Versions: 1.13.0
Reporter: HULING
Assignee: Julian Hyde
SQL :
select sum(ss_list_price) SM ,count(ss_list_price) NT,count(distinct ss_list_price) DNT
from store_sales
The type of 'salary' is double
An exception occurs when the following rules are used:
AggregateExpandDistinctAggregatesRule.JOIN
AggregateReduceFunctionsRule.INSTANCE
java.lang.AssertionError: Type mismatch:
rowtype of new rel:
RecordType(BIGINT SM, BIGINT NOT NULL NT, BIGINT NOT NULL DNT) NOT NULL
rowtype of set:
RecordType(DOUBLE SM, BIGINT NOT NULL NT, BIGINT NOT NULL DNT) NOT NULL
at org.apache.calcite.util.Litmus$1.fail(Litmus.java:31)
at org.apache.calcite.plan.RelOptUtil.equal(RelOptUtil.java:1873)
at org.apache.calcite.plan.volcano.RelSubset.add(RelSubset.java:271)
at org.apache.calcite.plan.volcano.RelSet.add(RelSet.java:85)
at org.apache.calcite.plan.volcano.VolcanoPlanner.addRelToSet(VolcanoPlanner.java:1645)
at org.apache.calcite.plan.volcano.VolcanoPlanner.registerImpl(VolcanoPlanner.java:1591)
at org.apache.calcite.plan.volcano.VolcanoPlanner.register(VolcanoPlanner.java:863)
at org.apache.calcite.plan.volcano.VolcanoPlanner.ensureRegistered(VolcanoPlanner.java:883)
at org.apache.calcite.plan.volcano.VolcanoPlanner.ensureRegistered(VolcanoPlanner.java:1767)
at org.apache.calcite.plan.volcano.VolcanoRuleCall.transformTo(VolcanoRuleCall.java:135)
at org.apache.calcite.plan.RelOptRuleCall.transformTo(RelOptRuleCall.java:234)
at org.apache.calcite.rel.rules.AggregateReduceFunctionsRule.reduceAggs(AggregateReduceFunctionsRule.java:181)
at org.apache.calcite.rel.rules.AggregateReduceFunctionsRule.onMatch(AggregateReduceFunctionsRule.java:110)
at org.apache.calcite.plan.volcano.VolcanoRuleCall.onMatch(VolcanoRuleCall.java:212)
at org.apache.calcite.plan.volcano.VolcanoPlanner.findBestExp(VolcanoPlanner.java:650)
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)