Return-Path: Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: (qmail 3814 invoked from network); 27 Oct 2009 17:47:23 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 27 Oct 2009 17:47:23 -0000 Received: (qmail 29888 invoked by uid 500); 27 Oct 2009 17:47:22 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 29847 invoked by uid 500); 27 Oct 2009 17:47:22 -0000 Mailing-List: contact derby-dev-help@db.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: Delivered-To: mailing list derby-dev@db.apache.org Received: (qmail 29839 invoked by uid 99); 27 Oct 2009 17:47:22 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 27 Oct 2009 17:47:22 +0000 X-ASF-Spam-Status: No, hits=-10.5 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 27 Oct 2009 17:47:20 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id D65CF234C046 for ; Tue, 27 Oct 2009 10:46:59 -0700 (PDT) Message-ID: <1923431719.1256665619876.JavaMail.jira@brutus> Date: Tue, 27 Oct 2009 17:46:59 +0000 (UTC) From: "Dag H. Wanvik (JIRA)" To: derby-dev@db.apache.org Subject: [jira] Updated: (DERBY-4426) With generated columns, INSERT with DEFAULT inside a VALUES clause inside a UNION fails. In-Reply-To: <765014550.1256663819371.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/DERBY-4426?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Dag H. Wanvik updated DERBY-4426: --------------------------------- Description: Repro on trunk: create table mytab (i int generated always as (j*2), j int); insert into mytab values (default,1) union values (default,2); ERROR XJ001: Java exception: 'ASSERT FAILED col[0] is null: org.apache.derby.shared.common.sanity.AssertFailure'. java.sql.SQLException: Java exception: 'ASSERT FAILED col[0] is null: org.apache.derby.shared.common.sanity.AssertFailure'. at org.apache.derby.impl.jdbc.SQLExceptionFactory40.getSQLException(SQLExceptionFactory40.java:95) at org.apache.derby.impl.jdbc.Util.newEmbedSQLException(Util.java:142) at org.apache.derby.impl.jdbc.Util.javaException(Util.java:299) at org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(TransactionResourceImpl.java:403) at org.apache.derby.impl.jdbc.TransactionResourceImpl.handleException(TransactionResourceImpl.java:346) at org.apache.derby.impl.jdbc.EmbedConnection.handleException(EmbedConnection.java:2204) at org.apache.derby.impl.jdbc.ConnectionChild.handleException(ConnectionChild.java:81) at org.apache.derby.impl.jdbc.EmbedStatement.executeStatement(EmbedStatement.java:1323) at org.apache.derby.impl.jdbc.EmbedStatement.execute(EmbedStatement.java:625) at org.apache.derby.impl.jdbc.EmbedStatement.execute(EmbedStatement.java:555) at org.apache.derby.impl.tools.ij.ij.executeImmediate(ij.java:329) at org.apache.derby.impl.tools.ij.utilMain.doCatch(utilMain.java:521) at org.apache.derby.impl.tools.ij.utilMain.runScriptGuts(utilMain.java:363) at org.apache.derby.impl.tools.ij.utilMain.go(utilMain.java:261) 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) Caused by: java.sql.SQLException: Java exception: 'ASSERT FAILED col[0] is null: org.apache.derby.shared.common.sanity.AssertFailure'. at org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(SQLExceptionFactory.java:45) at org.apache.derby.impl.jdbc.SQLExceptionFactory40.wrapArgsForTransportAcrossDRDA(SQLExceptionFactory40.java:119) at org.apache.derby.impl.jdbc.SQLExceptionFactory40.getSQLException(SQLExceptionFactory40.java:70) ... 17 more Caused by: org.apache.derby.shared.common.sanity.AssertFailure: ASSERT FAILED col[0] is null at org.apache.derby.shared.common.sanity.SanityManager.THROWASSERT(SanityManager.java:162) at org.apache.derby.shared.common.sanity.SanityManager.THROWASSERT(SanityManager.java:147) at org.apache.derby.impl.store.access.sort.MergeSort.checkColumnTypes(MergeSort.java:474) at org.apache.derby.impl.store.access.sort.MergeInserter.insert(MergeInserter.java:98) at org.apache.derby.impl.sql.execute.SortResultSet.loadSorter(SortResultSet.java:326) at org.apache.derby.impl.sql.execute.SortResultSet.openCore(SortResultSet.java:270) at org.apache.derby.impl.sql.execute.InsertResultSet.open(InsertResultSet.java:415) at org.apache.derby.impl.sql.GenericPreparedStatement.executeStmt(GenericPreparedStatement.java:436) at org.apache.derby.impl.sql.GenericPreparedStatement.execute(GenericPreparedStatement.java:317) at org.apache.derby.impl.jdbc.EmbedStatement.executeStatement(EmbedStatement.java:1235) was: Repro on trunk: create table mytab (i int generated always as (j*2), j int); insert into tt values (default,1) union values (default,2); ERROR XJ001: Java exception: 'ASSERT FAILED col[0] is null: org.apache.derby.shared.common.sanity.AssertFailure'. java.sql.SQLException: Java exception: 'ASSERT FAILED col[0] is null: org.apache.derby.shared.common.sanity.AssertFailure'. at org.apache.derby.impl.jdbc.SQLExceptionFactory40.getSQLException(SQLExceptionFactory40.java:95) at org.apache.derby.impl.jdbc.Util.newEmbedSQLException(Util.java:142) at org.apache.derby.impl.jdbc.Util.javaException(Util.java:299) at org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(TransactionResourceImpl.java:403) at org.apache.derby.impl.jdbc.TransactionResourceImpl.handleException(TransactionResourceImpl.java:346) at org.apache.derby.impl.jdbc.EmbedConnection.handleException(EmbedConnection.java:2204) at org.apache.derby.impl.jdbc.ConnectionChild.handleException(ConnectionChild.java:81) at org.apache.derby.impl.jdbc.EmbedStatement.executeStatement(EmbedStatement.java:1323) at org.apache.derby.impl.jdbc.EmbedStatement.execute(EmbedStatement.java:625) at org.apache.derby.impl.jdbc.EmbedStatement.execute(EmbedStatement.java:555) at org.apache.derby.impl.tools.ij.ij.executeImmediate(ij.java:329) at org.apache.derby.impl.tools.ij.utilMain.doCatch(utilMain.java:521) at org.apache.derby.impl.tools.ij.utilMain.runScriptGuts(utilMain.java:363) at org.apache.derby.impl.tools.ij.utilMain.go(utilMain.java:261) 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) Caused by: java.sql.SQLException: Java exception: 'ASSERT FAILED col[0] is null: org.apache.derby.shared.common.sanity.AssertFailure'. at org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(SQLExceptionFactory.java:45) at org.apache.derby.impl.jdbc.SQLExceptionFactory40.wrapArgsForTransportAcrossDRDA(SQLExceptionFactory40.java:119) at org.apache.derby.impl.jdbc.SQLExceptionFactory40.getSQLException(SQLExceptionFactory40.java:70) ... 17 more Caused by: org.apache.derby.shared.common.sanity.AssertFailure: ASSERT FAILED col[0] is null at org.apache.derby.shared.common.sanity.SanityManager.THROWASSERT(SanityManager.java:162) at org.apache.derby.shared.common.sanity.SanityManager.THROWASSERT(SanityManager.java:147) at org.apache.derby.impl.store.access.sort.MergeSort.checkColumnTypes(MergeSort.java:474) at org.apache.derby.impl.store.access.sort.MergeInserter.insert(MergeInserter.java:98) at org.apache.derby.impl.sql.execute.SortResultSet.loadSorter(SortResultSet.java:326) at org.apache.derby.impl.sql.execute.SortResultSet.openCore(SortResultSet.java:270) at org.apache.derby.impl.sql.execute.InsertResultSet.open(InsertResultSet.java:415) at org.apache.derby.impl.sql.GenericPreparedStatement.executeStmt(GenericPreparedStatement.java:436) at org.apache.derby.impl.sql.GenericPreparedStatement.execute(GenericPreparedStatement.java:317) at org.apache.derby.impl.jdbc.EmbedStatement.executeStatement(EmbedStatement.java:1235) > With generated columns, INSERT with DEFAULT inside a VALUES clause inside a UNION fails. > ----------------------------------------------------------------------------------------- > > Key: DERBY-4426 > URL: https://issues.apache.org/jira/browse/DERBY-4426 > Project: Derby > Issue Type: Bug > Components: SQL > Affects Versions: 10.5.1.1, 10.5.2.0, 10.5.3.0 > Reporter: Dag H. Wanvik > Priority: Minor > > Repro on trunk: > create table mytab (i int generated always as (j*2), j int); > insert into mytab values (default,1) union values (default,2); > ERROR XJ001: Java exception: 'ASSERT FAILED col[0] is null: org.apache.derby.shared.common.sanity.AssertFailure'. > java.sql.SQLException: Java exception: 'ASSERT FAILED col[0] is null: org.apache.derby.shared.common.sanity.AssertFailure'. > at org.apache.derby.impl.jdbc.SQLExceptionFactory40.getSQLException(SQLExceptionFactory40.java:95) > at org.apache.derby.impl.jdbc.Util.newEmbedSQLException(Util.java:142) > at org.apache.derby.impl.jdbc.Util.javaException(Util.java:299) > at org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(TransactionResourceImpl.java:403) > at org.apache.derby.impl.jdbc.TransactionResourceImpl.handleException(TransactionResourceImpl.java:346) > at org.apache.derby.impl.jdbc.EmbedConnection.handleException(EmbedConnection.java:2204) > at org.apache.derby.impl.jdbc.ConnectionChild.handleException(ConnectionChild.java:81) > at org.apache.derby.impl.jdbc.EmbedStatement.executeStatement(EmbedStatement.java:1323) > at org.apache.derby.impl.jdbc.EmbedStatement.execute(EmbedStatement.java:625) > at org.apache.derby.impl.jdbc.EmbedStatement.execute(EmbedStatement.java:555) > at org.apache.derby.impl.tools.ij.ij.executeImmediate(ij.java:329) > at org.apache.derby.impl.tools.ij.utilMain.doCatch(utilMain.java:521) > at org.apache.derby.impl.tools.ij.utilMain.runScriptGuts(utilMain.java:363) > at org.apache.derby.impl.tools.ij.utilMain.go(utilMain.java:261) > 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) > Caused by: java.sql.SQLException: Java exception: 'ASSERT FAILED col[0] is null: org.apache.derby.shared.common.sanity.AssertFailure'. > at org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(SQLExceptionFactory.java:45) > at org.apache.derby.impl.jdbc.SQLExceptionFactory40.wrapArgsForTransportAcrossDRDA(SQLExceptionFactory40.java:119) > at org.apache.derby.impl.jdbc.SQLExceptionFactory40.getSQLException(SQLExceptionFactory40.java:70) > ... 17 more > Caused by: org.apache.derby.shared.common.sanity.AssertFailure: ASSERT FAILED col[0] is null > at org.apache.derby.shared.common.sanity.SanityManager.THROWASSERT(SanityManager.java:162) > at org.apache.derby.shared.common.sanity.SanityManager.THROWASSERT(SanityManager.java:147) > at org.apache.derby.impl.store.access.sort.MergeSort.checkColumnTypes(MergeSort.java:474) > at org.apache.derby.impl.store.access.sort.MergeInserter.insert(MergeInserter.java:98) > at org.apache.derby.impl.sql.execute.SortResultSet.loadSorter(SortResultSet.java:326) > at org.apache.derby.impl.sql.execute.SortResultSet.openCore(SortResultSet.java:270) > at org.apache.derby.impl.sql.execute.InsertResultSet.open(InsertResultSet.java:415) > at org.apache.derby.impl.sql.GenericPreparedStatement.executeStmt(GenericPreparedStatement.java:436) > at org.apache.derby.impl.sql.GenericPreparedStatement.execute(GenericPreparedStatement.java:317) > at org.apache.derby.impl.jdbc.EmbedStatement.executeStatement(EmbedStatement.java:1235) -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.