id summary reporter owner description type status component version severity resolution keywords cc stage has_patch needs_docs needs_tests needs_better_patch easy ui_ux 18676 Django should do m2m deletes in a single query when possible Jeremy Dunck nobody "https://groups.google.com/forum/?fromgroups#!topic/django-developers/zoS8gAyZWjI As Anssi notes there: {{{ To me it seems there is no reason to do two queries in delete if the following conditions hold: - there are no signals sent for the deleted objects - the delete does not cascade further (actually you don't need to collect even in this case - you can do the cascade query completely in the DB without fetching the IDs first). }}} I think a good first-cut is auto-created intermediate table and no signals attached for that model. " Cleanup/optimization closed Database layer (models, ORM) 1.4 Normal fixed django@… Ready for checkin 1 0 0 0 0 0