Sometimes we have to import a lot of data temporarily. Or the logs in the database can become very big. Even with Loop optimization, the time to delete (or purge) these data is extremely long and expensive (memory). Mendix creates objects to define relationships and applies the deletion of records, all in one session.
Why not offer a fast deletion function (truncate table style) taking info account the relations between the entities ?
Agree. Mendix already optimizes Aggregate List functions, so for example a Retrieve from DB action, followed by a AggregateList.Count action, is optimized by Mendix to a Select COUNT(*) sql query.
The same thing should happen when you have a Retrieve from DB action, followed by a Delete action. There is no need to actually Retrieve the list, if it's only used to Delete it. This could be optimized to a Delete FROM sql query.