[
https://issues.apache.org/jira/browse/DRILL-2285?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Aman Sinha updated DRILL-2285:
------------------------------
Fix Version/s: (was: 1.2.0)
1.4.0
> Query fails when IN operator is provided a NULL literal
> -------------------------------------------------------
>
> Key: DRILL-2285
> URL: https://issues.apache.org/jira/browse/DRILL-2285
> Project: Apache Drill
> Issue Type: Bug
> Components: Query Planning & Optimization
> Affects Versions: 0.8.0
> Reporter: Abhishek Girish
> Assignee: Jinfeng Ni
> Fix For: 1.4.0
>
>
> Query 1 (Invalid literal):
> > select * from store_sales where ss_cdemo_sk in (abc) limit 1;
> No rows selected
> Query 2
> > select * from store_sales where ss_cdemo_sk in (null, 1046098) limit 1;
> Query failed: RelOptPlanner.CannotPlanException: Node
> [rel#8578:Subset#6.LOGICAL.ANY([]).[]] could not be implemented; planner
> state:
> Root: rel#8578:Subset#6.LOGICAL.ANY([]).[]
> Original rel:
> AbstractConverter(subset=[rel#8578:Subset#6.LOGICAL.ANY([]).[]],
> convention=[LOGICAL], DrillDistributionTraitDef=[ANY([])], sort=[[]]):
> rowcount = 1.7976931348623157E308, cumulative cost = {inf}, id = 8579
> SortRel(subset=[rel#8577:Subset#6.NONE.ANY([]).[]], fetch=[1]): rowcount =
> 1.7976931348623157E308, cumulative cost = {Infinity rows,
> 1.7976931348623157E308 cpu, 0.0 io, 0.0 network, 0.0 memory}, id = 8576
> ProjectRel(subset=[rel#8575:Subset#5.NONE.ANY([]).[]], *=[$0]): rowcount
> = 1.7976931348623157E308, cumulative cost = {1.7976931348623157E308 rows,
> 1.7976931348623157E308 cpu, 0.0 io, 0.0 network, 0.0 memory}, id = 8574
> JoinRel(subset=[rel#8573:Subset#4.NONE.ANY([]).[]], condition=[=($2,
> $3)], joinType=[inner]): rowcount = 1.7976931348623157E308, cumulative cost =
> {1.7976931348623157E308 rows, 0.0 cpu, 0.0 io, 0.0 network, 0.0 memory}, id =
> 8572
> ProjectRel(subset=[rel#8568:Subset#1.NONE.ANY([]).[]], $f0=[$0],
> $f1=[$1], $f2=[$1]): rowcount = 100.0, cumulative cost = {100.0 rows, 300.0
> cpu, 0.0 io, 0.0 network, 0.0 memory}, id = 8567
>
> EnumerableTableAccessRel(subset=[rel#8566:Subset#0.ENUMERABLE.ANY([]).[]],
> table=[[dfs, tpcds1_par, store_sales]]): rowcount = 100.0, cumulative cost =
> {100.0 rows, 101.0 cpu, 0.0 io, 0.0 network, 0.0 memory}, id = 8547
> AggregateRel(subset=[rel#8571:Subset#3.NONE.ANY([]).[]],
> group=[{0}]): rowcount = 1.7976931348623158E307, cumulative cost =
> {1.7976931348623158E307 rows, 0.0 cpu, 0.0 io, 0.0 network, 0.0 memory}, id =
> 8570
> ValuesRel(subset=[rel#8569:Subset#2.NONE.ANY([]).[]], tuples=[[{
> null }, { 1046098 }]]): rowcount = 2.0, cumulative cost = {2.0 rows, 1.0 cpu,
> 0.0 io, 0.0 network, 0.0 memory}, id = 8549
> Sets:
> Set#0, type: (DrillRecordRow[*, ss_cdemo_sk])
> rel#8566:Subset#0.ENUMERABLE.ANY([]).[], best=rel#8547,
> importance=0.5904900000000001
> ...
> ...
> Query 2 must not fail and should return results similar to Query 1. And if
> the expected behavior is right, the error message must be fixed.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)