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

From Bruce Momjian
Subject Re: SET CONSTRAINTS not schema-aware
Date
Msg-id 200306021726.h52HQHa16952@candle.pha.pa.us
Whole thread Raw
In response to Re: SET CONSTRAINTS not schema-aware  (Peter Eisentraut <peter_e@gmx.net>)
List pgsql-hackers
OK, added to TODO:
Allow SET CONSTRAINTS to be qualified by schema/table

Peter, I assume SET CONSTRAINTS can't control a domain's constraints ---
it isn't actually a data object in the transaction.  Am I right?

---------------------------------------------------------------------------

Peter Eisentraut wrote:
> Tom Lane writes:
> 
> > Right.  In SQL92 constraint names have to be unique within the table's
> > schema.  Postgres allows two different tables to have similarly-named
> > constraints, and that difference is the root of the issue.
> 
> But that should not prevent us from assigning an explicit schema to each
> constraint, as we in fact currently do.  This issue is a bit more tricky
> than it seems.  For example, constraints may also belong to a domain, so
> even if we allowed SET CONSTRAINTS a.b.c it is still not clear that "b" is
> a table.
> 
> -- 
> Peter Eisentraut   peter_e@gmx.net
> 
> 
> ---------------------------(end of broadcast)---------------------------
> TIP 2: you can get off all lists at once with the unregister command
>     (send "unregister YourEmailAddressHere" to majordomo@postgresql.org)
> 

--  Bruce Momjian                        |  http://candle.pha.pa.us pgman@candle.pha.pa.us               |  (610)
359-1001+  If your life is a hard drive,     |  13 Roberts Road +  Christ can be your backup.        |  Newtown Square,
Pennsylvania19073
 


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Some quick notes about extending libpq for new protocol
Next
From: Tom Lane
Date:
Subject: Re: Proposal for Re-ordering CONF (was: Re: GUC and postgresql.conf docs)