Subject | Help with a DELETE command |
---|---|
Author | Robert DiFalco |
Post date | 2004-12-05T21:04:34Z |
Without using ON DELETE or Triggers, how can I best do the following?
DELETE
FROM Child JOIN Parent ON Child.F_ID = Parent.F_CHILD_ID
WHERE Parent.F_FOO = 1;
I know the above is illegal, but it captures the query I would like to
delete with. I tried the following but for some reason it locked up the
database completely -- not even an error message:
DELETE
FROM Child
WHERE Child.F_ID
IN (SELECT Parent.F_CHILD_ID FROM Parent WHERE
Parent.F_FOO = 1);
Any thoughts?
Btw, this is FB 1.0.3 on Windows.
DELETE
FROM Child JOIN Parent ON Child.F_ID = Parent.F_CHILD_ID
WHERE Parent.F_FOO = 1;
I know the above is illegal, but it captures the query I would like to
delete with. I tried the following but for some reason it locked up the
database completely -- not even an error message:
DELETE
FROM Child
WHERE Child.F_ID
IN (SELECT Parent.F_CHILD_ID FROM Parent WHERE
Parent.F_FOO = 1);
Any thoughts?
Btw, this is FB 1.0.3 on Windows.