• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: core data migration - delete old store
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: core data migration - delete old store


  • Subject: Re: core data migration - delete old store
  • From: Dave Fernandes <email@hidden>
  • Date: Fri, 22 Jul 2011 00:26:27 -0400

On 2011-07-21, at 12:16 PM, Roland King wrote:

> Great - thanks for this - gets me started, I've found the documentation quite dense and soon I have to pitch in and just give it a go (I have a model I need to update in my test app and I really don't want to toss the data).
>
> I need to hunt around the NSManagedObjectModel class a bit more, clearly, there are methods there I don't know enough about. I assume there are ways to enumerate the models in the bundle, figure out which one is the 'current'

+[NSManagedObjectModel mergedModelFromBundles:]

> one and which one may match the store

+[NSManagedObjectModel mergedModelFromBundles:forStoreMetadata:]

> , will go read the class docs when they've finished d/l'ing. I saw some of the methods for making an on-the-fly migration, I'll try those out too see if they work.
>
> I think lightweight is going to do it for this change. One attribute deleted, one entity added, one mapping added, one attribute added (with a  default). It's not a bad way to get my feet wet with migration actually, I can afford to bungle it up, I can save the sqlite file before I start and give it few cracks. Ok that's the weekend!

_______________________________________________

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

References: 
 >core data migration - delete old store (From: Roland King <email@hidden>)
 >Re: core data migration - delete old store (From: Dave Fernandes <email@hidden>)
 >Re: core data migration - delete old store (From: Roland King <email@hidden>)

  • Prev by Date: Re: CGEventRef with function key
  • Next by Date: Determine architecture of a running application
  • Previous by thread: Re: core data migration - delete old store
  • Next by thread: Re: core data migration - delete old store
  • Index(es):
    • Date
    • Thread