Hello, I would like to make a query which deletes those records from table1, which are not included in table2. Tables can be linked with an ID field. Thanks for any help
Hello, I would like to make a query which deletes those records from table1, which are not included in table2. Tables can be linked with an ID field. Thanks for any help
Hey hklein,
This should work
Code:delete * FROM t1 where t1.id not in (select t2.id from t2);
Hello,
thank you, shouldn't I use any join...?
I'm not sure if there is a performance benefit, but using the where clause to "join" tables instead of the JOIN keyword is done sometimes and as long as it gets you to the same result w/o a big hit on performance.....![]()
Hello,
thanks for your time and help. It works smoothly![]()
No problem