Skip site navigation (1) Skip section navigation (2)

bug in 7.0

From: Don Baccus <dhogaza(at)pacifier(dot)com>
To: pgsql-hackers(at)postgreSQL(dot)org
Subject: bug in 7.0
Date: 2000-02-28 15:16:01
Message-ID: 3.0.1.32.20000228071601.00fc90a0@mail.pacifier.com (view raw or flat)
Thread:
Lists: pgsql-hackers
This is probably related to Lockhart's changes to allow
not null/not deferrable to work (foreign key stuff).  I'm
sympathetic, I looked at gram.y for awhile myself trying to
figure a way out of the problem and didn't find a good
solution.

Anyway:

donb=# create table bar(i integer unique not null);
ERROR:  parser: parse error at or near "not"
donb=# create table bar(i integer not null unique);
ERROR:  parser: parse error at or near "unique"
donb=# create table bar(i integer unique);
NOTICE:  CREATE TABLE/UNIQUE will create implicit index 'bar_i_key' for
table 'bar'
CREATE
donb=# 


Ouch.   Fails on "primary key not null", etc too (though the
not null is redundant in this case).

The data model I'm porting from Oracle fails several hundred
times now because of this little problem...I guess my last
snapshot was just before Thomas' committed those changes,
otherwise I would've caught them before beta.



- Don Baccus, Portland OR <dhogaza(at)pacifier(dot)com>
  Nature photos, on-line guides, Pacific Northwest
  Rare Bird Alert Service and other goodies at
  http://donb.photo.net.

Responses

pgsql-hackers by date

Next:From: Tom LaneDate: 2000-02-28 15:20:29
Subject: Re: [HACKERS] Re: ALTER TABLE DROP COLUMN
Previous:From: Tom LaneDate: 2000-02-28 15:14:07
Subject: Re: [HACKERS] having and union in v7beta

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group