You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@quickstep.apache.org by "Zuyu Zhang (JIRA)" <ji...@apache.org> on 2017/09/14 16:41:00 UTC

[jira] [Closed] (QUICKSTEP-95) Exception raised if the project expressions of a node in a query plan is empty

     [ https://issues.apache.org/jira/browse/QUICKSTEP-95?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Zuyu Zhang closed QUICKSTEP-95.
-------------------------------
    Resolution: Fixed
      Assignee: Zuyu Zhang

> Exception raised if the project expressions of a node in a query plan is empty
> ------------------------------------------------------------------------------
>
>                 Key: QUICKSTEP-95
>                 URL: https://issues.apache.org/jira/browse/QUICKSTEP-95
>             Project: Apache Quickstep
>          Issue Type: Bug
>          Components: Storage
>            Reporter: Zuyu Zhang
>            Assignee: Zuyu Zhang
>
> The problem is that [tuple_slot_bytes_](https://github.com/apache/incubator-quickstep/blob/master/storage/SplitRowStoreTupleStorageSubBlock.cpp#L128) is ZERO if the project expression is empty, and [later](https://github.com/apache/incubator-quickstep/blob/master/storage/SplitRowStoreTupleStorageSubBlock.cpp#L142) results in a divide-by-zero exception.
> It is easy to reproduce:
> $ create table r (a int, b char(20));
> $ insert into r values(1, 'madison');
> $ create table s (a int, c float);
> $ select s.a from r, s where r.a > 0;
> {noformat}
> I0619 18:26:45.097215 1944100864 PhysicalGenerator.cpp:196] Optimized physical plan:
> TopLevelPlan
> +-plan=NestedLoopsJoin
> | +-left=Selection
> | | +-input=TableReference[relation=r]
> | | | +-AttributeReference[id=0,name=a,relation=r,type=Int]
> | | | +-AttributeReference[id=1,name=b,relation=r,type=Char(20)]
> | | +-filter_predicate=Greater
> | | | +-AttributeReference[id=0,name=a,relation=r,type=Int]
> | | | +-Literal[value=0,type=Int]
> | | +-project_expressions=
> | |   +-[]
> | +-right=TableReference[relation=s]
> | | +-AttributeReference[id=2,name=a,relation=s,type=Int]
> | | +-AttributeReference[id=3,name=c,relation=s,type=Float]
> | +-join_predicate=Literal[value=true]
> | +-project_expressions=
> |   +-AttributeReference[id=2,name=a,relation=s,type=Int]
> +-output_attributes=
>   +-AttributeReference[id=2,name=a,relation=s,type=Int]
> {noformat}
> Floating point exception: 8



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)