Brain Freeze - Request Delete Syntax Help
From: Buck Turgidson <jc_va_at_hotmail.com>
Date: Fri, 29 Feb 2008 09:13:01 -0500
Message-ID: <OpUxj.22325$y05.12777@newsfe22.lga>
select * from
mytable.
where ( aggr = '1' OR ( aggr = '3' AND agg_d <> 'X' ) ).
delete from mytable
where ( aggr <> '1' and ( aggr <> '3' AND agg_d = 'X' ) ).
Received on Fri Feb 29 2008 - 08:13:01 CST
Date: Fri, 29 Feb 2008 09:13:01 -0500
Message-ID: <OpUxj.22325$y05.12777@newsfe22.lga>
I need to reverse the logic of a SELECT statement, and change it into a
DELETE statement.
Do I have this right? Does this:
select * from
mytable.
where ( aggr = '1' OR ( aggr = '3' AND agg_d <> 'X' ) ).
Convert to this for a table that is loaded without the above where clause?
delete from mytable
where ( aggr <> '1' and ( aggr <> '3' AND agg_d = 'X' ) ).
Received on Fri Feb 29 2008 - 08:13:01 CST