[
https://issues.apache.org/jira/browse/CALCITE-6458?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Corvin Kuebler updated CALCITE-6458:
------------------------------------
Description:
Hey!
Running the following unit test in JdbcAdapterTest fails with
{code:java}
@Test void testAioob() {
CalciteAssert.model(JdbcTest.SCOTT_MODEL)
.query("select job\n"
+ "from scott.emp e left join scott.dept d\n"
+ "on e.deptno = d.deptno and e.job not in (select distinct job
from scott.bonus b)")
.runs();
}
{code}
{code:java}
Caused by: java.lang.ArrayIndexOutOfBoundsException: Index 5 out of bounds for
length 5
at
org.apache.calcite.util.mapping.Mappings$PartialMapping.getTargetOpt(Mappings.java:1324)
at
org.apache.calcite.util.mapping.Mappings$AbstractMapping.getTarget(Mappings.java:943)
at
org.apache.calcite.rex.RexPermuteInputsShuttle.visitInputRef(RexPermuteInputsShuttle.java:87)
at
org.apache.calcite.rex.RexPermuteInputsShuttle.visitInputRef(RexPermuteInputsShuttle.java:35)
{code}
was:
Hey!
Running the following unit test in JdbcAdapterTest fails with
{code:java}
@Test void testAioob() {
CalciteAssert.model(JdbcTest.SCOTT_MODEL)
.query("select job\n"
+ "from scott.emp e left join scott.dept d\n"
+ "on e.deptno = d.deptno and e.job not in (select distinct job
from scott.bonus b)")
.runs();
}
{code}
{code:java}
java.lang.ArrayIndexOutOfBoundsException: Index 5 out of bounds for length 5
{code}
> RexPermuteInputsShuttle produces ArrayIndexOutOfBoundsException for join
> conditions with subselect
> --------------------------------------------------------------------------------------------------
>
> Key: CALCITE-6458
> URL: https://issues.apache.org/jira/browse/CALCITE-6458
> Project: Calcite
> Issue Type: Bug
> Components: core
> Affects Versions: 1.37.0
> Reporter: Corvin Kuebler
> Priority: Major
>
> Hey!
> Running the following unit test in JdbcAdapterTest fails with
> {code:java}
> @Test void testAioob() {
> CalciteAssert.model(JdbcTest.SCOTT_MODEL)
> .query("select job\n"
> + "from scott.emp e left join scott.dept d\n"
> + "on e.deptno = d.deptno and e.job not in (select distinct
> job from scott.bonus b)")
> .runs();
> }
> {code}
> {code:java}
> Caused by: java.lang.ArrayIndexOutOfBoundsException: Index 5 out of bounds
> for length 5
> at
> org.apache.calcite.util.mapping.Mappings$PartialMapping.getTargetOpt(Mappings.java:1324)
> at
> org.apache.calcite.util.mapping.Mappings$AbstractMapping.getTarget(Mappings.java:943)
> at
> org.apache.calcite.rex.RexPermuteInputsShuttle.visitInputRef(RexPermuteInputsShuttle.java:87)
> at
> org.apache.calcite.rex.RexPermuteInputsShuttle.visitInputRef(RexPermuteInputsShuttle.java:35)
> {code}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)