NOT {NULL|DEFERRABLE} (was: bug in 7.0)

From: wieck(at)debis(dot)com (Jan Wieck)
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Don Baccus <dhogaza(at)pacifier(dot)com>, pgsql-hackers(at)postgreSQL(dot)org
Subject: NOT {NULL|DEFERRABLE} (was: bug in 7.0)
Date: 2000-02-28 22:18:34
Message-ID: m12PYUs-0003kGC@orion.SAPserv.Hamburg.dsh.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Tom Lane wrote:

> Don Baccus <dhogaza(at)pacifier(dot)com> writes:
> > This is probably related to Lockhart's changes to allow
> > not null/not deferrable to work (foreign key stuff).
>
> Yeah, we need a better answer for NOT DEFERRABLE. Thomas just did a
> quick & dirty kluge to allow testing of foreign keys, but as you see
> it's broken a number of other things...
>
> I still like the idea of turning NOT NULL into a single token before
> it gets to the grammar, but Thomas was dissatisfied with that plan.

I would be able to undo Thomas' changes to the parser (plus
your fix for SEQUENCE) and put our idea of token lookahead
into instead. The changes are locally to gram.y, and anything
works as expected.

It's a kludge too, mucking around with a

#define yylex() pg_yylex()

at the beginning, then later #undef'ining it again and
creating a function pg_yylex() that calls the real yylex().
Since we insist on bison and ship a gram.c for the others,
There can't be any portability problems.

I'd like to discuss this with Thomas on the phone before
committing, but IIRC he's off right now. So what do others
think?

Jan

--

#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me. #
#========================================= wieck(at)debis(dot)com (Jan Wieck) #

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Don Baccus 2000-02-28 22:37:02 Re: NOT {NULL|DEFERRABLE} (was: bug in 7.0)
Previous Message Massimo Dal Zotto 2000-02-28 18:45:41 Re: [HACKERS] Syslog and pg_options (for RPMs)