Re: SET CONSTRAINTS not schema-aware - Mailing list pgsql-hackers

From Bruno Wolff III
Subject Re: SET CONSTRAINTS not schema-aware
Date
Msg-id 20030511174944.GB710@wolff.to
Whole thread Raw
In response to SET CONSTRAINTS not schema-aware  (Peter Eisentraut <peter_e@gmx.net>)
Responses Re: SET CONSTRAINTS not schema-aware  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On Sun, May 11, 2003 at 18:46:32 +0200, Peter Eisentraut <peter_e@gmx.net> wrote:
> SET CONSTRAINTS doesn't allow you to schema-qualify a constraint name.
> Here's an example:
> 
> create schema test;
> create table test.foo (a int primary key);
> create table test.bar (b int primary key, c int constraint myconstraint references test.foo);
> 
> -- This succeeds even though schema "test" is not in the search path:
> set constraints myconstraint immediate;
> 
> -- This is what should work:
> set constraints test.myconstraint immediate;
> ERROR:  parser: parse error at or near "." at character 21
> 
> Comments?

I am pretty sure I saw some comments in the discussion about sequence
naming that constraints are per table and giving them a schema name
makes no sense. The table they are for has the schema name in it.



pgsql-hackers by date:

Previous
From: Bruno Wolff III
Date:
Subject: Re: problem building tablefunc in 7.4
Next
From: Oleg Bartunov
Date:
Subject: tsearch upgrade documentation needed