Return-Path: Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: (qmail 13096 invoked from network); 16 Nov 2007 17:45:07 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 16 Nov 2007 17:45:07 -0000 Received: (qmail 99384 invoked by uid 500); 16 Nov 2007 17:44:53 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 99360 invoked by uid 500); 16 Nov 2007 17:44:53 -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 99346 invoked by uid 99); 16 Nov 2007 17:44:53 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 16 Nov 2007 09:44:53 -0800 X-ASF-Spam-Status: No, hits=-100.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 16 Nov 2007 17:44:50 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id B2F4A714245 for ; Fri, 16 Nov 2007 09:44:43 -0800 (PST) Message-ID: <30485150.1195235083711.JavaMail.jira@brutus> Date: Fri, 16 Nov 2007 09:44:43 -0800 (PST) From: "Bryan Pendleton (JIRA)" To: derby-dev@db.apache.org Subject: [jira] Commented: (DERBY-3177) Dropping columns casues auto_increment field to be lost In-Reply-To: <14726012.1194361010766.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/DERBY-3177?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12543147 ] Bryan Pendleton commented on DERBY-3177: ---------------------------------------- Charlie, what do you think is the status of this issue at this point? In my environment, the DERBY-3175 patch makes the bug2.sql script run correctly, so my feeling is that we should mark this issue as a resolved duplicate of DERBY-3175. However, in one of your comments to DERBY-3175 ( https://issues.apache.org/jira/browse/DERBY-3175#action_12541670 ) you indicated that you are still seeing problems even after the DERBY-3175 fix. Can you provide a repro script that demonstrates those problems? Please let us know what you think would be best to do regarding this JIRA issue. > Dropping columns casues auto_increment field to be lost > ------------------------------------------------------- > > Key: DERBY-3177 > URL: https://issues.apache.org/jira/browse/DERBY-3177 > Project: Derby > Issue Type: Bug > Affects Versions: 10.3.1.4 > Environment: Windows XP SP2 > JVM: Hotspot JVM 1.6 > Derby: 10.3.1000004.561794 > Reporter: Charlie Hubbard > Assignee: Bryan Pendleton > Attachments: bug2.sql, migration-bug.sql > > > I have a DB that I've been updating over time, and I've run into this bug. After running this script Messages.ID table looses it's auto incrementing column after running the script to completion. If I create a virgin DB and run this script against the Message table's ID column looses it's auto increment data type. If you comment out the last three alter table statements the column's auto increment feature is not lost. You don't have to insert any data into the database for this to happen. > I tried creating a simpler script to expose this problem, but was unsuccessful. I tried something like: > create table Messages ( > Name varchar(256), > KillThis varchar(256), > id INTEGER NOT NULL GENERATED ALWAYS AS IDENTITY (START WITH 1, INCREMENT BY 1), > CONSTRAINT MESSAGES_id_pk PRIMARY KEY(id) > ); > alter table Messages drop column KillThis; > However, this DID NOT EXPOSE THE BUG. So there is something else at work causing this problem. See the attached script to recreate the problem. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.