Re: [HACKERS] FOREIGN KEY and shift/reduce

From: Thomas Lockhart <lockhart(at)alumni(dot)caltech(dot)edu>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Jan Wieck <wieck(at)debis(dot)com>, PostgreSQL HACKERS <pgsql-hackers(at)postgreSQL(dot)org>
Subject: Re: [HACKERS] FOREIGN KEY and shift/reduce
Date: 1999-12-10 16:36:54
Message-ID: 38512C26.A1DB607@alumni.caltech.edu
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> Bruce and I were talking about that last night. I think it could be
> fixed by having the grammar treat
> NOT DEFERRABLE
> DEFERRABLE
> INITIALLY IMMEDIATE
> INITIALLY DEFERRED
> as independent ColConstraintElem clauses, and then have a post-pass in
> analyze.c that folds the flags into the preceding REFERENCES clause
> (and complains if they don't appear right after a REFERENCES clause).
> Pretty grotty, especially since you probably wouldn't want to do the
> same thing for the other uses of these clauses in TableConstraint
> and CreateTrigStmt ... but possibly cleaner than a lexer hack.

analyze.c already does a grotty scan of the constraint clauses to push
them out into the place Vadim's implementation expects them. We could
identify the FK clauses and push them somewhere else, no problem
(well, at least in principle ;).

- Thomas

--
Thomas Lockhart lockhart(at)alumni(dot)caltech(dot)edu
South Pasadena, California

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 1999-12-10 16:38:42 Re: [HACKERS] 6.6 release
Previous Message Bruce Momjian 1999-12-10 16:21:52 Re: [HACKERS] 6.6 release