Re: DELETE with JOIN syntax - Mailing list pgsql-general

From Brian Wong
Subject Re: DELETE with JOIN syntax
Date
Msg-id e1c904a40507271331429f6450@mail.gmail.com
Whole thread Raw
In response to Re: DELETE with JOIN syntax  (Stephan Szabo <sszabo@megazone.bigpanda.com>)
List pgsql-general
On 7/27/05, Stephan Szabo <sszabo@megazone.bigpanda.com> wrote:
>
> I think the where t2.column_id is null where column_id is the joining
> column makes this a form of not exists, so maybe:
>
> DELETE FROM t1 WHERE NOT EXISTS (SELECT 1 FROM t2 WHERE t2.column_id =
> t1.columnid);
>
>

This looks good. Thanks.

pgsql-general by date:

Previous
From: John DeSoi
Date:
Subject: Re: GUID for postgreSQL
Next
From: Scott Marlowe
Date:
Subject: Re: GUID for postgreSQL