[ 
https://issues.apache.org/jira/browse/DRILL-2234?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16419988#comment-16419988
 ] 

Boaz Ben-Zvi commented on DRILL-2234:
-------------------------------------

This bug still exists in 1.13 . However the forthcoming PR with the work on 
Hash Join Spilling will cure this bug, as the failing code ( HashJoinProbeGen ) 
was eliminated:
{code}
0: jdbc:drill:zk=local> alter session set `planner.slice_target` = 1;
+-------+--------------------------------+
|  ok   |            summary             |
+-------+--------------------------------+
| true  | planner.slice_target updated.  |
+-------+--------------------------------+
1 row selected (1.35 seconds)
0: jdbc:drill:zk=local> alter session set `planner.enable_hashagg` = false;
+-------+----------------------------------+
|  ok   |             summary              |
+-------+----------------------------------+
| true  | planner.enable_hashagg updated.  |
+-------+----------------------------------+
1 row selected (0.113 seconds)
0: jdbc:drill:zk=local> alter session set `planner.enable_streamagg` = true;
+-------+------------------------------------+
|  ok   |              summary               |
+-------+------------------------------------+
| true  | planner.enable_streamagg updated.  |
+-------+------------------------------------+
1 row selected (0.115 seconds)
0: jdbc:drill:zk=local> alter session set `exec.errors.verbose` = true;
+-------+-------------------------------+
|  ok   |            summary            |
+-------+-------------------------------+
| true  | exec.errors.verbose updated.  |
+-------+-------------------------------+
1 row selected (0.105 seconds)
0: jdbc:drill:zk=local> select * from (select l_orderkey from 
cp.`tpch/lineitem.parquet` group by l_orderkey) l inner join 
cp.`tpch/orders.parquet` o on l.l_orderkey = o.o_orderkey where o.o_custkey = 
10;
SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further 
details.
+-------------+-------------+------------+----------------+---------------+--------------+------------------+------------------+-----------------+--------------------------------------------------------------------------------+
| l_orderkey  | o_orderkey  | o_custkey  | o_orderstatus  | o_totalprice  | 
o_orderdate  | o_orderpriority  |     o_clerk      | o_shippriority  |          
                         o_comment                                    |
+-------------+-------------+------------+----------------+---------------+--------------+------------------+------------------+-----------------+--------------------------------------------------------------------------------+
| 11431       | 11431       | 10         | F              | 230289.6      | 
1992-08-02   | 2-HIGH           | Clerk#000000055  | 0               | press 
ideas use slyly regular pinto beans. furiously                           |
| 17668       | 17668       | 10         | F              | 322342.37     | 
1994-11-26   | 3-MEDIUM         | Clerk#000000511  | 0               | posits. 
final, express warhorses detect by the blithely regular                |
| 20964       | 20964       | 10         | F              | 298876.15     | 
1992-03-31   | 1-URGENT         | Clerk#000000041  | 0               | press 
deposits affix furiously fluffily                                        |
| 26785       | 26785       | 10         | O              | 148499.07     | 
1996-06-25   | 5-LOW            | Clerk#000000376  | 0               | 
requests-- ironic pinto beans nag accordin                                     |
| 27200       | 27200       | 10         | O              | 173191.03     | 
1995-08-22   | 3-MEDIUM         | Clerk#000000476  | 0               | xes wake 
carefully sil                                                         |
| 28898       | 28898       | 10         | O              | 122287.09     | 
1995-05-29   | 5-LOW            | Clerk#000000423  | 0               | the 
unusual packages. blithely expre                                           |
| 33095       | 33095       | 10         | F              | 239749.78     | 
1994-02-16   | 4-NOT SPECIFIED  | Clerk#000000771  | 0               | riously 
packages. boldly bold instructions boost furiously slyly regular de    |
| 55492       | 55492       | 10         | O              | 187966.88     | 
1995-09-20   | 1-URGENT         | Clerk#000000105  | 0               | totes. 
quickly bold pinto beans about the careful                              |
| 55749       | 55749       | 10         | F              | 102944.7      | 
1992-05-04   | 1-URGENT         | Clerk#000000925  | 0               | wake 
quickly about the blithely ironic water                                   |
| 56775       | 56775       | 10         | F              | 42578.88      | 
1994-10-11   | 1-URGENT         | Clerk#000000010  | 0               |  
blithely express, pending packages. slyly quiet dep                           |
| 9862        | 9862        | 10         | O              | 193015.83     | 
1997-10-10   | 2-HIGH           | Clerk#000000168  | 0               | among 
the instructions was after the slyly special packages. final, final hoc  |
| 18307       | 18307       | 10         | F              | 158346.75     | 
1993-02-03   | 5-LOW            | Clerk#000000033  | 0               |  express 
sheaves would hinder above the slyly even deposits.                   |
| 20195       | 20195       | 10         | O              | 99067.93      | 
1998-08-02   | 1-URGENT         | Clerk#000000423  | 0               | gular 
accounts. slyly bold                                                     |
| 21729       | 21729       | 10         | F              | 309286.33     | 
1992-12-07   | 5-LOW            | Clerk#000000577  | 0               | e 
requests. quickly car                                                        |
| 35972       | 35972       | 10         | F              | 39228.39      | 
1993-12-25   | 1-URGENT         | Clerk#000000002  | 0               | ly up 
the ironic deposits. slyly ironic escapades toward the fluffily unu      |
| 40387       | 40387       | 10         | O              | 180784.32     | 
1998-02-21   | 1-URGENT         | Clerk#000000704  | 0               | lithely 
enticing requests. blithely even waters are quickly quickl             |
| 49506       | 49506       | 10         | O              | 152699.84     | 
1997-04-26   | 1-URGENT         | Clerk#000000497  | 0               | express 
theodolites about                                                      |
| 50086       | 50086       | 10         | F              | 72065.37      | 
1992-09-20   | 3-MEDIUM         | Clerk#000000681  | 0               | refully. 
regular deposits are. s                                               |
| 54400       | 54400       | 10         | O              | 132173.75     | 
1997-07-09   | 3-MEDIUM         | Clerk#000000675  | 0               |  the 
final, express deposits-- blithely r                                      |
| 58979       | 58979       | 10         | O              | 69241.25      | 
1997-07-06   | 1-URGENT         | Clerk#000000870  | 0               |  
carefully ironic excuses. slyly silent deposits detect unusual deposits. car  |
| 1602        | 1602        | 10         | F              | 6751.57       | 
1993-08-05   | 5-LOW            | Clerk#000000660  | 0               | 
deposits. busily silent instructions haggle furiously. fin                     |
| 13124       | 13124       | 10         | F              | 57676.34      | 
1993-12-18   | 3-MEDIUM         | Clerk#000000862  | 0               | ggle 
quickly according to the carefully even pac                               |
| 16548       | 16548       | 10         | F              | 158826.22     | 
1992-02-06   | 4-NOT SPECIFIED  | Clerk#000000851  | 0               | lites 
haggle slyly. slyly silent accounts                                      |
| 30306       | 30306       | 10         | O              | 30726.71      | 
1995-06-15   | 4-NOT SPECIFIED  | Clerk#000000707  | 0               | gular, 
busy grouches detect furiously. dogg                                    |
| 30882       | 30882       | 10         | O              | 65297.83      | 
1996-10-11   | 4-NOT SPECIFIED  | Clerk#000000176  | 0               | usly 
enticing packag                                                           |
| 34311       | 34311       | 10         | F              | 209263.18     | 
1994-09-06   | 2-HIGH           | Clerk#000000108  | 0               | into 
beans. even deposits wake slyly regular foxes. express asymptotes         |
| 43078       | 43078       | 10         | O              | 61921.02      | 
1998-04-08   | 5-LOW            | Clerk#000000356  | 0               | special 
packages. furious                                                      |
+-------------+-------------+------------+----------------+---------------+--------------+------------------+------------------+-----------------+--------------------------------------------------------------------------------+
27 rows selected (6.806 seconds)
{code}

 

> IOOB when streaming aggregate is on the left side of hash join
> --------------------------------------------------------------
>
>                 Key: DRILL-2234
>                 URL: https://issues.apache.org/jira/browse/DRILL-2234
>             Project: Apache Drill
>          Issue Type: Bug
>          Components: Execution - Relational Operators
>            Reporter: Mehant Baid
>            Assignee: Boaz Ben-Zvi
>            Priority: Major
>             Fix For: Future
>
>
> This issue is similar to DRILL-2107. 
> Issue can be reproduced by enabling SwapJoinRule in DrillRuleSets and running 
> the following query.
> alter session set `planner.slice_target` = 1;
> alter session set `planner.enable_hashagg` = false;
> alter session set `planner.enable_streamagg` = true;
> select l_suppkey, sum(l_extendedprice)/sum(l_quantity) as avg_price 
> from cp.`tpch/lineitem.parquet` where l_orderkey in
> (select o_orderkey from cp.`tpch/orders.parquet` where o_custkey = 2) 
> group by l_suppkey having sum(l_extendedprice)/sum(l_quantity) > 1850.0;



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to