1
0
mirror of https://github.com/postgres/postgres.git synced 2025-11-03 09:13:20 +03:00

Merge the Constraint and FkConstraint node types into a single type.

This was foreseen to be a good idea long ago, but nobody had got round
to doing it.  The recent patch for deferred unique constraints made
transformConstraintAttrs() ugly enough that I decided it was time.
This change will also greatly simplify parsing of deferred CHECK constraints,
if anyone ever gets around to implementing that.

While at it, add a location field to Constraint, and use that to provide
an error cursor for some of the constraint-related error messages.
This commit is contained in:
Tom Lane
2009-07-30 02:45:38 +00:00
parent 78aef14c59
commit 060baf2784
12 changed files with 394 additions and 515 deletions

View File

@@ -7,7 +7,7 @@
* Portions Copyright (c) 1996-2009, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* $PostgreSQL: pgsql/src/include/nodes/nodes.h,v 1.223 2009/06/11 14:49:11 momjian Exp $
* $PostgreSQL: pgsql/src/include/nodes/nodes.h,v 1.224 2009/07/30 02:45:37 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -364,7 +364,6 @@ typedef enum NodeTag
T_RangeTblEntry,
T_SortGroupClause,
T_WindowClause,
T_FkConstraint,
T_PrivGrantee,
T_FuncWithArgs,
T_AccessPriv,