Re: howto delete using a join ?

From: Joshua Tolley <eggyknap(at)gmail(dot)com>
To: Andreas <maps(dot)on(at)gmx(dot)net>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: howto delete using a join ?
Date: 2010-07-24 11:47:24
Message-ID: 4c4ad2d6.0bb48c0a.7970.5678@mx.google.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

On Sat, Jul 24, 2010 at 06:05:57AM +0200, Andreas wrote:
> Hi,
>
> is there a way to delete from a table using information from another
> table to decide if a row should be dropped?

Yes. See DELETE ... USING

http://www.postgresql.org/docs/8.4/interactive/sql-delete.html

--
Joshua Tolley / eggyknap
End Point Corporation
http://www.endpoint.com

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Torsten Zühlsdorff 2010-07-26 07:41:23 Re: [TRIGGER] Returning values from BEFORE UPDATE trigger, without using them
Previous Message Dmitriy Igrishin 2010-07-24 09:22:32 Re: howto delete using a join ?