db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Knut Anders Hatlen (JIRA)" <j...@apache.org>
Subject [jira] [Created] (DERBY-6593) NPE when joining table with Lucene VTI
Date Mon, 02 Jun 2014 12:33:02 GMT
Knut Anders Hatlen created DERBY-6593:
-----------------------------------------

             Summary: NPE when joining table with Lucene VTI
                 Key: DERBY-6593
                 URL: https://issues.apache.org/jira/browse/DERBY-6593
             Project: Derby
          Issue Type: Bug
          Components: SQL
    Affects Versions: 10.11.0.0
            Reporter: Knut Anders Hatlen


I'm seeing a NullPointerException when joining a table with a Lucene VTI.

Here's a script that reproduces the NPE:

{noformat}
ij version 10.11
ij> connect 'jdbc:derby:memory:db;create=true';
ij> create table t(id int primary key, x varchar(20));
0 rows inserted/updated/deleted
ij> insert into t values (1, 'abc');
1 row inserted/updated/deleted
ij> call syscs_util.syscs_register_tool( 'luceneSupport', true );
0 rows inserted/updated/deleted
ij> call lucenesupport.createindex('app', 't', 'x', null);
0 rows inserted/updated/deleted
ij> select * from t natural join (select * from table (t__x(t.x, null, 100, null)) lt)
lt;
ERROR 38000: The exception 'java.lang.NullPointerException' was thrown while evaluating an
expression.
ERROR XJ001: Java exception: ': java.lang.NullPointerException'.
{noformat}

Full stack trace:

{noformat}
java.lang.NullPointerException
	at org.apache.derby.iapi.types.DataType.setValue(DataType.java:537)
	at org.apache.derby.exe.aced8940a7x0146x5c7fx5474x0000188928898.g0(Unknown Source)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:483)
	at org.apache.derby.impl.services.reflect.ReflectMethod.invoke(ReflectMethod.java:46)
	at org.apache.derby.impl.sql.execute.VTIResultSet.openCore(VTIResultSet.java:251)
	at org.apache.derby.impl.sql.execute.JoinResultSet.openCore(JoinResultSet.java:146)
	at org.apache.derby.impl.sql.execute.ProjectRestrictResultSet.openCore(ProjectRestrictResultSet.java:181)
	at org.apache.derby.impl.sql.execute.BasicNoPutResultSetImpl.open(BasicNoPutResultSetImpl.java:266)
	at org.apache.derby.impl.sql.GenericPreparedStatement.executeStmt(GenericPreparedStatement.java:470)
	at org.apache.derby.impl.sql.GenericPreparedStatement.execute(GenericPreparedStatement.java:349)
	at org.apache.derby.impl.jdbc.EmbedStatement.executeStatement(EmbedStatement.java:1338)
	at org.apache.derby.impl.jdbc.EmbedStatement.execute(EmbedStatement.java:704)
	at org.apache.derby.impl.jdbc.EmbedStatement.execute(EmbedStatement.java:631)
	at org.apache.derby.impl.tools.ij.ij.executeImmediate(ij.java:367)
	at org.apache.derby.impl.tools.ij.utilMain.doCatch(utilMain.java:527)
	at org.apache.derby.impl.tools.ij.utilMain.runScriptGuts(utilMain.java:372)
	at org.apache.derby.impl.tools.ij.utilMain.go(utilMain.java:245)
	at org.apache.derby.impl.tools.ij.Main.go(Main.java:229)
	at org.apache.derby.impl.tools.ij.Main.mainCore(Main.java:184)
	at org.apache.derby.impl.tools.ij.Main.main(Main.java:75)
	at org.apache.derby.tools.ij.main(ij.java:59)
{noformat}



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Mime
View raw message