Rixx
Registered User.
- Local time
- Today, 13:52
- Joined
- Mar 3, 2005
- Messages
- 25
It seems my database is a continuous array of never ending problems! My current problem is that of a DELETE query!
Is there any one out there that knows how to delete a complete record from a Products table (with the ProductID as the criteria), even if there are related records in other tables (e.g. Order details and Order queries).
At the moment I have Multiple Command buttons on a form that is running each query separately, deleting the related information first, before finally deleting the Record in the Items table (the last button).
It would be so much better if I could do this in one operation e.g. I have Items marked 'Discontinued' in my products table and a query that deletes all records that are marked as 'Yes' for Discontinued. But it wont do this because there are related records in other tables! I receive a Microsoft locked error
Any help will be greatly appreciated.
Thanks
Is there any one out there that knows how to delete a complete record from a Products table (with the ProductID as the criteria), even if there are related records in other tables (e.g. Order details and Order queries).
At the moment I have Multiple Command buttons on a form that is running each query separately, deleting the related information first, before finally deleting the Record in the Items table (the last button).
It would be so much better if I could do this in one operation e.g. I have Items marked 'Discontinued' in my products table and a query that deletes all records that are marked as 'Yes' for Discontinued. But it wont do this because there are related records in other tables! I receive a Microsoft locked error

Any help will be greatly appreciated.
Thanks