pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Martín Marqués <martin@bugs.unl.edu.ar>
Cc: pgsql-sql@postgresql.org
Cc: pgsql-general@postgresql.org
Subject: Re: [SQL] delete with cascade
Date: Fri, 04 May 2001 18:24:09 -0400
Message-ID: <1698.989015049@sss.pgh.pa.us> (raw)
In-Reply-To: <01050211140201.25070@bugs>
References: <01050211140201.25070@bugs>

=?iso-8859-1?q?Mart=EDn=20Marqu=E9s?= <martin@bugs.unl.edu.ar> writes:
> I was reading the manuals on DELETE and I saw this:
> By default DELETE will delete tuples in the table specified and all its
> sub-tables. If you wish to only update the specific table mentioned, you 
> should use the ONLY clause. 

> I just don't understand what sub-tables means.

It means inheritance children, ie, tables you created with INHERIT
from the specified table.

> Does it mean that it will 
> delete rows on other tables which are referenced with a FOREIGN KEY to the 
> row which will be deleted?

Foreign key deletion is an unrelated feature.

			regards, tom lane



view thread (3+ messages)

Message-ID: <1698.989015049@sss.pgh.pa.us>
Permalink:  ../1698.989015049@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/1698.989015049@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-sql@postgresql.org
  Cc: tgl@sss.pgh.pa.us, martin@bugs.unl.edu.ar, pgsql-general@postgresql.org
  Subject: Re: [SQL] delete with cascade
  In-Reply-To: <1698.989015049@sss.pgh.pa.us>
  References: <01050211140201.25070@bugs> <1698.989015049@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox