Removing Rows in Foreign Keys

From: brew(at)theMode(dot)com
To: pgsql-novice(at)postgresql(dot)org
Subject: Removing Rows in Foreign Keys
Date: 2005-04-04 06:56:56
Message-ID: Pine.BSF.4.58.0504040247360.86885@themode.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice


Well, I confess. Although I've several databases running on postgreSQL
I've never done more than just store data. (no constaints, no triggers, no
functions, not even any transactions) I'm setting up a new schema for a
new database and am learning about using foreign keys.

Is there a SQL command that removes both a row in a table and the rows in
other tables that reference it or do I have to do it manually?

Sort of like 'DELETE CASCADE....." which I tried, to no avail. Perusing
the manual didn't reveal anything....

brew

==========================================================================
Strange Brew (brew(at)theMode(dot)com)
Check out my Stock Option Covered Call website http://www.callpix.com
and my Musician's Online Database Exchange http://www.TheMode.com
==========================================================================

In response to

Responses

Browse pgsql-novice by date

  From Date Subject
Next Message Michael Fuhr 2005-04-04 07:47:50 Re: Removing Rows in Foreign Keys
Previous Message Aarni Ruuhimäki 2005-04-04 06:00:34 Re: Database Encoding