Deletes all records in a C/SIDE table that fall within a specified range.
Specifies whether to run the C/AL code in the.
If this parameter is true, then the code in the OnDelete trigger will be executed. If this parameter is false (default), then the code in the OnDelete trigger will not be executed.
The default value is false.
Identifies the table in which the deletion will occur. Only those records selected by the filters set for Record are deleted.
This example requires that you create a Record variable for the Customer table named CustomerRec.
// This C/AL code: WHILE CustomerRec.FIND('-') DO CustomerRec.DELETE; // Performs the same operation as: CustomerRec.DELETEALL;
When RunTrigger is false (the default) the DELETEALL function in this example is much faster than the DELETE function because it requires only one call to the server, while the first method requires multiple calls. If RunTrigger is true, there will not be any gain in performance because each record needs to be loaded to the client anyway, in order to execute the OnDelete trigger.