Re: NOT and AND problem

From: "Richard Jones" <r(dot)d(dot)jones(at)ed(dot)ac(dot)uk>
To: "Viorel Dragomir" <bc(at)vio(dot)ro>, <pgsql-sql(at)postgresql(dot)org>, <terry(at)ashtonwoodshomes(dot)com>, <dmitry(at)openratings(dot)com>
Subject: Re: NOT and AND problem
Date: 2003-07-17 15:09:45
Message-ID: 00db01c34c75$754a6400$5192d781@lib.ed.ac.uk
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Hello,

Just to say thanks for such fast responses. The full working query is
indeed as suggested (I cut the demo query down when I posted it, as it's got
some awfully long names in it in real life):

DELETE FROM eulepersongroup2workspaceitem
WHERE NOT EXISTS (
SELECT 1 FROM workspaceitem WHERE workspace_item_id =
eulepersongroup2workspaceitem.workspace_item_id
) OR NOT EXISTS (
SELECT 1 FROM epersongroup WHERE eperson_group_id =
eulepersongroup2workspaceitem.eperson_group_id
);

Thanks very much for your help.

Regards

Richard

Richard Jones
-----------------------
Systems Developer
Theses Alive! - www.thesesalive.ac.uk
Edinburgh University Library
r(dot)d(dot)jones(at)ed(dot)ac(dot)uk
0131 651 1611

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Stephan Szabo 2003-07-17 15:39:17 Re: parse error for function def
Previous Message terry 2003-07-17 14:52:25 Re: NOT and AND problem