Core Data Batch Deleting

Number:rdar://15183213 Date Originated:10/8/2013
Status:Open Resolved:
Product:iOS SDK Product Version:iOS 7
Classification:Feature (New) Reproducible:

Picture an RSS reader, podcast client, or Twitter or ADN app. Those apps continually pull down more data -- and, as they do, they need to delete older data.

Often they need to delete a *ton* of older data. And that deletion may be pretty simple: delete everything older than 31 days, for instance.

Currently this is a pain: it's necessary to fetch each object and delete it. That takes more time and uses more memory than a SQL call.

Better would be the ability to delete based on a predicate -- something like this:

[managedObjectContext deleteObjectsMatchingPredicate:predicate entityName:entityName];


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!