From: | Jan Wieck <JanWieck(at)Yahoo(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | Stephan Szabo <sszabo(at)megazone23(dot)bigpanda(dot)com>, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: Should this require CASCADE? |
Date: | 2002-07-10 23:34:53 |
Message-ID: | 3D2CC49D.B56E3F85@Yahoo.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Tom Lane wrote:
>
> Stephan Szabo <sszabo(at)megazone23(dot)bigpanda(dot)com> writes:
> > On Wed, 10 Jul 2002, Tom Lane wrote:
> >> DROP TABLE foo RESTRICT;
> >>
> >> Should this succeed? Or should it be necessary to say DROP CASCADE to
> >> get rid of the foreign-key reference to foo?
>
> > I think the above should fail. If someone was adding restrict since it
> > was optional, I'd guess they were doing so in advance for the days when
> > we'd actually restrict the drop.
>
> Sorry if I wasn't clear: we never had the RESTRICT/CASCADE syntax at all
> until now. What I'm intending though is that DROP with no option will
> default to DROP RESTRICT, which means that a lot of cases that used to
> be "gotchas" will now fail until you say CASCADE. I wrote RESTRICT in
> my example just to emphasize that the intended behavior is RESTRICT.
I think the idea was to have it default to CASCADE for this release, not
to break existing code right away. Then 7.3 is transition time and
RESTRICT will be the default from the next release on.
If so, this has to go into the release notes.
Jan
>
> So if you prefer, imagine same example but you merely say
> DROP TABLE foo;
> Does your answer change?
>
> regards, tom lane
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo(at)postgresql(dot)org
--
#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me. #
#================================================== JanWieck(at)Yahoo(dot)com #
From | Date | Subject | |
---|---|---|---|
Next Message | Bradley Baetz | 2002-07-10 23:44:01 | Re: [INTERFACES] [pgaccess-users] RE: bugzilla.pgaccess.org |
Previous Message | Rod Taylor | 2002-07-10 23:27:47 | Re: Should this require CASCADE? |