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] Updated: (DERBY-4693) column rename looses 'identity' attribute.
Date Sat, 05 Jun 2010 11:53:53 GMT

     [ https://issues.apache.org/jira/browse/DERBY-4693?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Knut Anders Hatlen updated DERBY-4693:
--------------------------------------

        Fix Version/s:     (was: 10.6.1.1)
     Issue & fix info: [Newcomer, Repro attached]  (was: [Newcomer])
    Affects Version/s: 10.3.1.4

This bug is present all the way back to the introduction of rename column in Derby 10.3, so
I'm updating affects versions to reflect that.

Cleared the fix version field since it is unknown when the bug will be fixed. Added the repro
attached flag to indicate that the steps to reproduce are provided in the bug description.

> column rename looses 'identity' attribute.
> ------------------------------------------
>
>                 Key: DERBY-4693
>                 URL: https://issues.apache.org/jira/browse/DERBY-4693
>             Project: Derby
>          Issue Type: Bug
>          Components: SQL
>    Affects Versions: 10.3.1.4, 10.6.1.0
>         Environment: ubuntu, java 1.5
>            Reporter: Brett Sutton
>            Priority: Minor
>
> renaming an identity column causes the column to loose its 'identity' attribute.
> you can reproduce the problem as follows:
> CREATE TABLE njr_version ( id INTEGER generated always as identity, databaseVersion INTEGER);
> insert into njr_version (databaseVersion) values (10);
> -- column inserted successfully.
> rename column njr_version.id to idVersion;
> insert into njr_version (databaseVersion) values (10);
> Error: Column 'IDVERSION'  cannot accept a NULL value.
> To compound this problem there is no way to restore the renamed column's identity attribute
as the alter command doesn't let you set an identity attribute. The only work around is to
create a new table and copy the data across.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message