Hi Mark

delete from prices p
where not exists (
  select 1
  from dockets d
  where p.forest = d.forest
  and p.comp = d.comp
  and p.contractor = d.contractor)

Cheers,
Carl

-----Original Message-----
From: Mark Howard [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, 5 July 2000 7:01 AM
To: Multiple recipients of list delphi
Subject: [DUG]: SQL


Help please

How can I do, in Paradox :

delete from prices p
where p.forest, p.comp, p.contractor
not in
(select distinct forest, comp, contractor from dockets)

ie I want to delete each record in prices where the set of (forest, comp,
contractor)
does not appear in dockets.

Thanks

Mark
---------------------------------------------------------------------------
    New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
                  Website: http://www.delphi.org.nz

Reply via email to