db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mamta Satoor <msat...@gmail.com>
Subject Re: [jira] Updated: (DERBY-158) PRIMARY KEY does not imply NOT NULL
Date Tue, 08 Mar 2005 22:11:47 GMT
Hi Jeremy,

I was wondering if you added test cases for alter table for this bug? 

thanks,
Mamta


On Sat, 5 Mar 2005 05:45:47 +0100 (CET), Jeremy Boynes (JIRA)
<derby-dev@db.apache.org> wrote:
>     [ http://issues.apache.org/jira/browse/DERBY-158?page=history ]
> 
> Jeremy Boynes updated DERBY-158:
> --------------------------------
> 
>    Attachment: derby-158-1.patch
> 
> Patch to TableElementList that implicitly adds NOT NULL to columns included in a PRIMARY
KEY constraint contained in a CREATE TABLE statement. However, it does not allow UNIQUE to
be added in CREATE TABLE if any of the columns are NULL; similarly UNIQUE or PRIMARY KEY constraints
cannot be added with ALTER TABLE if any of the columns are nullable.
> 
> I am posting this first for review as a couple of tests still need to be updated.
> 
> > PRIMARY KEY does not imply NOT NULL
> > -----------------------------------
> >
> >          Key: DERBY-158
> >          URL: http://issues.apache.org/jira/browse/DERBY-158
> >      Project: Derby
> >         Type: Bug
> >   Components: SQL
> >     Reporter: Bernt M. Johnsen
> >     Assignee: Jeremy Boynes
> >     Priority: Minor
> >  Attachments: derby-158-1.patch
> >
> > PRIMARY KEY does not imply NOT NULL. Derby issues error message:
> > ij> create table tab (i integer primary key);
> > ERROR 42831: 'I' cannot be a column of a primary key or unique key because it can
contain null values.
> > This is neither compliant with SQL-92 nor with SQL-99 (Feature E141-08, I think).
> 
> --
> 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
> -
> If you want more information on JIRA, or have a bug to report see:
>   http://www.atlassian.com/software/jira
> 
>

Mime
View raw message