You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by "Yip Ng (JIRA)" <ji...@apache.org> on 2006/11/09 01:00:51 UTC

[jira] Updated: (DERBY-2018) NullPointerException in CREATE VIEW ... VALUES NULL;

     [ http://issues.apache.org/jira/browse/DERBY-2018?page=all ]

Yip Ng updated DERBY-2018:
--------------------------

    Attachment: derby2018-trunk-stat01.txt
                derby2018-trunk-diff01.txt

Attaching derby2018-trunk-diff01.txt.  This is a simple fix where it catches untyped null in CreateViewNode at bind phase (same logic as CursorNode) and throws the exception.
derbyall passes except for the following tests which already failed before this patch.

derbyall/derbynetclientmats/derbynetclientmats.fail:junitTests/derbyNet/CompatibilityTest.java
derbyall/derbynetclientmats/derbynetmats.fail:derbynet/ShutDownDBWhenNSShutsDownTest.junit
derbyall/derbynetmats/derbynetmats.fail:derbynet/ShutDownDBWhenNSShutsDownTest.junit 

JUnit suite passes.  

> NullPointerException in CREATE VIEW ... VALUES NULL;
> ----------------------------------------------------
>
>                 Key: DERBY-2018
>                 URL: http://issues.apache.org/jira/browse/DERBY-2018
>             Project: Derby
>          Issue Type: Bug
>          Components: SQL
>    Affects Versions: 10.2.1.6
>         Environment: Java 1.5.0_06-b05
>            Reporter: Christian d'Heureuse
>         Assigned To: Yip Ng
>            Priority: Minor
>         Attachments: derby2018-trunk-diff01.txt, derby2018-trunk-stat01.txt
>
>
> The following statement produces a NullPointerException:
>    CREATE VIEW v1 (f1) AS VALUES NULL;
> Stack trace:
> ----------------------------------------------------------------
> 2006-10-30 12:39:31.750 GMT:
>  Booting Derby version The Apache Software Foundation - Apache Derby - 10.2.1.6 - (452058): instance c013800d-010e-993b-512f-00000012f418
> on database directory C:\temp_sys\temp_Derby_TestErr_db
> Database Class Loader started - derby.database.classpath=''
> 2006-10-30 12:39:38.484 GMT Thread[main,5,main] (XID = 122), (SESSIONID = 0), (DATABASE = c:\temp_sys\temp_Derby_TestErr_db), (DRDAID = null), Cleanup action starting
> 2006-10-30 12:39:38.484 GMT Thread[main,5,main] (XID = 122), (SESSIONID = 0), (DATABASE = c:\temp_sys\temp_Derby_TestErr_db), (DRDAID = null), Failed Statement is: CREATE VIEW v1 (f1) AS VALUES NULL
> java.lang.NullPointerException
>         at org.apache.derby.impl.sql.catalog.SYSCOLUMNSRowFactory.makeRow(Unknown Source)
>         at org.apache.derby.impl.sql.catalog.DataDictionaryImpl.addDescriptorArray(Unknown Source)
>         at org.apache.derby.impl.sql.execute.CreateViewConstantAction.executeConstantAction(Unknown Source)
>         at org.apache.derby.impl.sql.execute.MiscResultSet.open(Unknown Source)
>         at org.apache.derby.impl.sql.GenericPreparedStatement.execute(Unknown Source)
>         at org.apache.derby.impl.jdbc.EmbedStatement.executeStatement(Unknown Source)
>         at org.apache.derby.impl.jdbc.EmbedStatement.execute(Unknown Source)
>         at org.apache.derby.impl.jdbc.EmbedStatement.execute(Unknown Source)
>         at org.apache.derby.impl.tools.ij.ij.executeImmediate(Unknown Source)
>         at org.apache.derby.impl.tools.ij.utilMain.doCatch(Unknown Source)
>         at org.apache.derby.impl.tools.ij.utilMain.go(Unknown Source)
>         at org.apache.derby.impl.tools.ij.Main.go(Unknown Source)
>         at org.apache.derby.impl.tools.ij.Main.mainCore(Unknown Source)
>         at org.apache.derby.impl.tools.ij.Main14.main(Unknown Source)
>         at org.apache.derby.tools.ij.main(Unknown Source)

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira