Re: Deleting all objects from Core Data store
Re: Deleting all objects from Core Data store
- Subject: Re: Deleting all objects from Core Data store
- From: email@hidden
- Date: Mon, 14 Jan 2008 02:35:05 -0800
>Part of my CoreData application requires to delete all objects of a
>specific set. I am able to find objects using a Predicate and delete a
>singular object. How do I go about deleting all objects from a set?
Using a for statement ? There's no "DELETE FROM", because Core Data isn't a relational database.
If you have a lot of objects to delete in the set, refactor your model to add a object to hold the set (with a cascade rule) and when required, delete it.
:: marcelo.alves
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden