how can i delete from table A while comparing two fields A.P and A.C to table B's B.P and B.C while looking for all matches of B.R = 1 ?
actually neither of the following work but it should go into the direction, unfortunately i can't figure out how...
DELETE FROM A WHERE (A.P = B.P AND A.C = B.C where B.C = 1)
DELETE FROM A WHERE (SELECT B.P, B.C FROM B WHERE B = 1)
DELETE FROM A
FROM A INNER JOIN B ON A.P = B.P AND A.C = B.C
WHERE B.C = 1
The double FROM sometimes throws people off.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With